annotate config.h @ 7:162accc5d36d

remove cascade layout
author paulo@thepaulopc
date Tue, 14 Jun 2011 00:03:39 -0700
parents 0968b3739b8d
children e749c30135e9
rev   line source
paulo@0 1 /* (C)opyright MMVI-MMVII Anselm R. Garbe <garbeam at gmail dot com>
paulo@0 2 * See LICENSE file for license details.
paulo@0 3 */
paulo@0 4
paulo@0 5 /* appearance */
paulo@0 6 #define BORDERPX 1
paulo@0 7 #define FONT "6x9"
paulo@0 8 #define NORMBORDERCOLOR "#aaaaaa"
paulo@0 9 #define NORMBGCOLOR "#222222"
paulo@0 10 #define NORMFGCOLOR "#eeeeee"
paulo@0 11 #define SELBORDERCOLOR "#ff0000"
paulo@0 12 #define SELBGCOLOR "#222222"
paulo@0 13 #define SELFGCOLOR "#00ff00"
paulo@0 14 #define TOPBAR True /* False */
paulo@3 15 #define TASKBAR True /* False */
paulo@3 16 #define CLICK_TO_FOCUS True /* False */
paulo@0 17
paulo@0 18 /* behavior */
paulo@0 19 #define SNAP 10 /* pixel */
paulo@0 20 #define TAGS \
paulo@0 21 const char *tags[] = { "1", "2", "3", "4", "5", "6", "7", "8", "9", "0", NULL };
paulo@0 22 /* Query class:instance:title for regex matching info with following command:
paulo@0 23 * xprop | awk -F '"' '/^WM_CLASS/ { printf("%s:%s:",$4,$2) }; /^WM_NAME/ { printf("%s\n",$2) }' */
paulo@0 24 #define RULES \
paulo@0 25 static Rule rule[] = { \
paulo@0 26 /* class:instance:title regex tags regex isversatile */ \
paulo@0 27 { "Gimp", NULL, False }, \
paulo@0 28 { "MPlayer", NULL, False }, \
paulo@0 29 { "Acroread", NULL, False }, \
paulo@0 30 };
paulo@0 31
paulo@0 32 /* layout(s) */
paulo@0 33 #define LAYOUTS \
paulo@0 34 static Layout layout[] = { \
paulo@0 35 /* symbol function */ \
paulo@0 36 { " ", versatile }, \
paulo@0 37 { "@", spiral }, \
paulo@0 38 { "&", spiral_h }, \
paulo@0 39 { "X", monocle }, \
paulo@0 40 { "#", grid }, \
paulo@0 41 { "U", bstack }, \
paulo@0 42 { "!", tile }, \
paulo@0 43 /* first entry is default */ \
paulo@0 44 };
paulo@0 45 #define MASTER 650 /* per thousand */
paulo@0 46 #define NMASTER 1 /* clients in master area */
paulo@0 47
paulo@6 48 #define COMMANDMODE 1
paulo@6 49 #define INSERTMODE 2
paulo@6 50
paulo@0 51 /* key definitions */
paulo@0 52 #define MODKEY Mod4Mask
paulo@0 53 #define KEYS \
paulo@0 54 static Key key[] = { \
paulo@0 55 /* modifier key function argument */ \
paulo@6 56 { MODKEY, XK_Escape, setkeymode, { .i = COMMANDMODE } }, \
paulo@0 57 { MODKEY, XK_h, moveresize, "-25x 0y 0w 0h" }, \
paulo@0 58 { MODKEY, XK_l, moveresize, "25x 0y 0w 0h" }, \
paulo@0 59 { MODKEY, XK_j, moveresize, "0x 25y 0w 0h" }, \
paulo@0 60 { MODKEY, XK_k, moveresize, "0x -25y 0w 0h" }, \
paulo@0 61 { MODKEY|ControlMask, XK_h, moveresize, "0X 0y 0w 0h" }, \
paulo@0 62 { MODKEY|ControlMask, XK_l, moveresize, "9000X 0y 0w 0h" }, \
paulo@0 63 { MODKEY|ControlMask, XK_j, moveresize, "0x 9000Y 0w 0h" }, \
paulo@4 64 { MODKEY|ControlMask, XK_k, moveresize, "0x 0Y 0w 0h" }, \
paulo@0 65 { MODKEY|ShiftMask, XK_h, moveresize, "0x 0y -25w 0h" }, \
paulo@0 66 { MODKEY|ShiftMask, XK_l, moveresize, "0x 0y 25w 0h" }, \
paulo@0 67 { MODKEY|ShiftMask, XK_j, moveresize, "0x 0y 0w 25h" }, \
paulo@0 68 { MODKEY|ShiftMask, XK_k, moveresize, "0x 0y 0w -25h" }, \
paulo@0 69 };
paulo@0 70
paulo@4 71 #define MAX_TASKS 13 /* max number of apps in taskbar */
paulo@6 72
paulo@6 73 #define CMDKEYS \
paulo@6 74 static Key cmdkeys[] = { \
paulo@6 75 /* modifier keys function argument */ \
paulo@6 76 { 0, XK_Escape, clearcmd, { 0 } }, \
paulo@6 77 { ControlMask, XK_c, clearcmd, { 0 } }, \
paulo@6 78 { MODKEY|ShiftMask, XK_x, killclient, { 0 } }, \
paulo@6 79 { MODKEY|ShiftMask, XK_q, quit, { 0 } }, \
paulo@6 80 { 0, XK_i, setkeymode, { .i = INSERTMODE } }, \
paulo@6 81 { 0, XK_o, spawn, { .cmd = "/home/paulo/bin/myterm.sh" } }, \
paulo@6 82 { ShiftMask, XK_o, spawn_insert, { .cmd = "/home/paulo/bin/myterm.sh" } }, \
paulo@6 83 { 0, XK_backslash, spawn, { .cmd = "/home/paulo/bin/myterm.sh -e /home/paulo/bin/viclip.sh" } }, \
paulo@6 84 { ShiftMask, XK_backslash, spawn_insert, { .cmd = "/home/paulo/bin/myterm.sh -e /home/paulo/bin/viclip.sh" } }, \
paulo@6 85 { 0, XK_n, pushdown, { 0 } }, \
paulo@6 86 { ShiftMask, XK_n, pushup, { 0 } }, \
paulo@6 87 { 0, XK_j, focusnext, { 0 } }, \
paulo@6 88 { 0, XK_k, focusprev, { 0 } }, \
paulo@6 89 { 0, XK_Return, zoom, { 0 } }, \
paulo@6 90 { ShiftMask, XK_Return, zoom_insert, { 0 } }, \
paulo@6 91 { 0, XK_m, resizemaster, { .i = 15 } }, \
paulo@6 92 { ShiftMask, XK_m, resizemaster, { .i = -15 } }, \
paulo@6 93 { 0, XK_d, incnmaster, { .i = 1 } }, \
paulo@6 94 { ShiftMask, XK_d, incnmaster, { .i = -1 } }, \
paulo@6 95 { 0, XK_v, next_view, { .i = 1 } }, \
paulo@6 96 { ShiftMask, XK_v, next_view, { .i = -1 } }, \
paulo@6 97 { 0, XK_BackSpace, last_view, { 0 } }, \
paulo@6 98 { 0, XK_l, setlayout, { .i = -1 } }, \
paulo@6 99 { ShiftMask, XK_l, setlayout, { .i = -2 } }, \
paulo@6 100 };
paulo@6 101
paulo@6 102 #define COMMANDS \
paulo@6 103 static Command commands[] = { \
paulo@6 104 /* modifier (4 keys) keysyms (4 keys) function argument */ \
paulo@6 105 { {0, 0, 0, 0}, {XK_grave, XK_v, 0, 0}, view, { .i = -1 } }, \
paulo@6 106 { {0, 0, 0, 0}, {XK_1, XK_v, 0, 0}, view, { .i = 0 } }, \
paulo@6 107 { {0, 0, 0, 0}, {XK_2, XK_v, 0, 0}, view, { .i = 1 } }, \
paulo@6 108 { {0, 0, 0, 0}, {XK_3, XK_v, 0, 0}, view, { .i = 2 } }, \
paulo@6 109 { {0, 0, 0, 0}, {XK_4, XK_v, 0, 0}, view, { .i = 3 } }, \
paulo@6 110 { {0, 0, 0, 0}, {XK_5, XK_v, 0, 0}, view, { .i = 4 } }, \
paulo@6 111 { {0, 0, 0, 0}, {XK_6, XK_v, 0, 0}, view, { .i = 5 } }, \
paulo@6 112 { {0, 0, 0, 0}, {XK_7, XK_v, 0, 0}, view, { .i = 6 } }, \
paulo@6 113 { {0, 0, 0, 0}, {XK_8, XK_v, 0, 0}, view, { .i = 7 } }, \
paulo@6 114 { {0, 0, 0, 0}, {XK_9, XK_v, 0, 0}, view, { .i = 8 } }, \
paulo@6 115 { {0, 0, 0, 0}, {XK_0, XK_v, 0, 0}, view, { .i = 9 } }, \
paulo@6 116 { {0, ShiftMask, 0, 0}, {XK_grave, XK_v, 0, 0}, toggleversatile, { 0 } }, \
paulo@6 117 { {0, ShiftMask, 0, 0}, {XK_1, XK_v, 0, 0}, toggleview, { .i = 0 } }, \
paulo@6 118 { {0, ShiftMask, 0, 0}, {XK_2, XK_v, 0, 0}, toggleview, { .i = 1 } }, \
paulo@6 119 { {0, ShiftMask, 0, 0}, {XK_3, XK_v, 0, 0}, toggleview, { .i = 2 } }, \
paulo@6 120 { {0, ShiftMask, 0, 0}, {XK_4, XK_v, 0, 0}, toggleview, { .i = 3 } }, \
paulo@6 121 { {0, ShiftMask, 0, 0}, {XK_5, XK_v, 0, 0}, toggleview, { .i = 4 } }, \
paulo@6 122 { {0, ShiftMask, 0, 0}, {XK_6, XK_v, 0, 0}, toggleview, { .i = 5 } }, \
paulo@6 123 { {0, ShiftMask, 0, 0}, {XK_7, XK_v, 0, 0}, toggleview, { .i = 6 } }, \
paulo@6 124 { {0, ShiftMask, 0, 0}, {XK_8, XK_v, 0, 0}, toggleview, { .i = 7 } }, \
paulo@6 125 { {0, ShiftMask, 0, 0}, {XK_9, XK_v, 0, 0}, toggleview, { .i = 8 } }, \
paulo@6 126 { {0, ShiftMask, 0, 0}, {XK_0, XK_v, 0, 0}, toggleview, { .i = 9 } }, \
paulo@6 127 { {0, 0, 0, 0}, {XK_1, XK_l, 0, 0}, setlayout, { .i = 0 } }, \
paulo@6 128 { {0, 0, 0, 0}, {XK_2, XK_l, 0, 0}, setlayout, { .i = 1 } }, \
paulo@6 129 { {0, 0, 0, 0}, {XK_3, XK_l, 0, 0}, setlayout, { .i = 2 } }, \
paulo@6 130 { {0, 0, 0, 0}, {XK_4, XK_l, 0, 0}, setlayout, { .i = 3 } }, \
paulo@6 131 { {0, 0, 0, 0}, {XK_5, XK_l, 0, 0}, setlayout, { .i = 4 } }, \
paulo@6 132 { {0, 0, 0, 0}, {XK_6, XK_l, 0, 0}, setlayout, { .i = 5 } }, \
paulo@6 133 { {0, 0, 0, 0}, {XK_7, XK_l, 0, 0}, setlayout, { .i = 6 } }, \
paulo@6 134 { {0, 0, 0, 0}, {XK_grave, XK_t, 0, 0}, tag, { .i = -1 } }, \
paulo@6 135 { {0, 0, 0, 0}, {XK_1, XK_t, 0, 0}, tag, { .i = 0 } }, \
paulo@6 136 { {0, 0, 0, 0}, {XK_2, XK_t, 0, 0}, tag, { .i = 1 } }, \
paulo@6 137 { {0, 0, 0, 0}, {XK_3, XK_t, 0, 0}, tag, { .i = 2 } }, \
paulo@6 138 { {0, 0, 0, 0}, {XK_4, XK_t, 0, 0}, tag, { .i = 3 } }, \
paulo@6 139 { {0, 0, 0, 0}, {XK_5, XK_t, 0, 0}, tag, { .i = 4 } }, \
paulo@6 140 { {0, 0, 0, 0}, {XK_6, XK_t, 0, 0}, tag, { .i = 5 } }, \
paulo@6 141 { {0, 0, 0, 0}, {XK_7, XK_t, 0, 0}, tag, { .i = 6 } }, \
paulo@6 142 { {0, 0, 0, 0}, {XK_8, XK_t, 0, 0}, tag, { .i = 7 } }, \
paulo@6 143 { {0, 0, 0, 0}, {XK_9, XK_t, 0, 0}, tag, { .i = 8 } }, \
paulo@6 144 { {0, 0, 0, 0}, {XK_0, XK_t, 0, 0}, tag, { .i = 9 } }, \
paulo@6 145 { {0, ShiftMask, 0, 0}, {XK_1, XK_t, 0, 0}, toggletag, { .i = 0 } }, \
paulo@6 146 { {0, ShiftMask, 0, 0}, {XK_2, XK_t, 0, 0}, toggletag, { .i = 1 } }, \
paulo@6 147 { {0, ShiftMask, 0, 0}, {XK_3, XK_t, 0, 0}, toggletag, { .i = 2 } }, \
paulo@6 148 { {0, ShiftMask, 0, 0}, {XK_4, XK_t, 0, 0}, toggletag, { .i = 3 } }, \
paulo@6 149 { {0, ShiftMask, 0, 0}, {XK_5, XK_t, 0, 0}, toggletag, { .i = 4 } }, \
paulo@6 150 { {0, ShiftMask, 0, 0}, {XK_6, XK_t, 0, 0}, toggletag, { .i = 5 } }, \
paulo@6 151 { {0, ShiftMask, 0, 0}, {XK_7, XK_t, 0, 0}, toggletag, { .i = 6 } }, \
paulo@6 152 { {0, ShiftMask, 0, 0}, {XK_8, XK_t, 0, 0}, toggletag, { .i = 7 } }, \
paulo@6 153 { {0, ShiftMask, 0, 0}, {XK_9, XK_t, 0, 0}, toggletag, { .i = 8 } }, \
paulo@6 154 { {0, ShiftMask, 0, 0}, {XK_0, XK_t, 0, 0}, toggletag, { .i = 9 } }, \
paulo@6 155 };