Import dwm-win32-alpha1
[dwm-win32.git] / config.def.h
blob47a8ec9abc1c0147c787524bc339ce496e4f8ec7
1 /* See LICENSE file for copyright and license details. */
3 /* appearance */
4 static const COLORREF normbordercolor = RGB(204, 204, 204);
5 static const COLORREF normbgcolor = RGB(204, 204, 204);
6 static const COLORREF normfgcolor = RGB(0,0,0);
7 static const COLORREF selbordercolor = RGB(0,102,255);
8 static const COLORREF selbgcolor = RGB(0,102,255);
9 static const COLORREF selfgcolor = RGB(255,255,255);
11 static const unsigned int borderpx = 2; /* border pixel of windows */
12 static const unsigned int textmargin = 5; /* margin for the text displayed on the bar */
13 static bool showbar = true; /* false means no bar */
14 static bool topbar = true; /* false means bottom bar */
16 /* tagging */
17 static const char tags[][MAXTAGLEN] = { "1", "2", "3", "4", "5", "6", "7", "8", "9" };
18 static unsigned int tagset[] = {1, 1}; /* after start, first tag is selected */
20 static Rule rules[] = {
21 /* class title tags mask isfloating */
22 { "MozillaUIWindowClass", "- Mozilla Firefox", 1 << 8, false },
25 /* layout(s) */
26 static float mfact = 0.55; /* factor of master area size [0.05..0.95] */
28 static Layout layouts[] = {
29 /* symbol arrange function */
30 { "[]=", tile }, /* first entry is default */
31 { "><>", NULL }, /* no layout function means floating behavior */
32 { "[M]", monocle },
35 /* key definitions */
36 #define MODKEY (MOD_CONTROL | MOD_ALT)
37 #define TAGKEYS(KEY,TAG) \
38 { MODKEY, KEY, view, {.ui = 1 << TAG} }, \
39 { MODKEY|MOD_CONTROL, KEY, toggleview, {.ui = 1 << TAG} }, \
40 { MODKEY|MOD_SHIFT, KEY, tag, {.ui = 1 << TAG} }, \
41 { MODKEY|MOD_CONTROL|MOD_SHIFT, KEY, toggletag, {.ui = 1 << TAG} },
43 /* helper for spawning shell commands in the pre dwm-5.0 fashion */
44 #define SHCMD(cmd) { .v = (const char*[]){ "/bin/sh", "-c", cmd, NULL } }
46 /* commands */
47 static const char *termcmd[] = { "cmd.exe", NULL };
49 static Key keys[] = {
50 /* modifier key function argument */
51 { MODKEY, 'P', spawn, {.v = termcmd } },
52 { MODKEY|MOD_SHIFT, VK_RETURN, spawn, {.v = termcmd } },
53 { MODKEY, 'B', togglebar, {0} },
54 { MODKEY, 'J', focusstack, {.i = +1 } },
55 { MODKEY, 'K', focusstack, {.i = -1 } },
56 { MODKEY, 'H', setmfact, {.f = -0.05} },
57 { MODKEY, 'L', setmfact, {.f = +0.05} },
58 { MODKEY, 'I', showclientclassname, {0} },
59 { MODKEY, VK_RETURN, zoom, {0} },
60 { MODKEY, VK_TAB, view, {0} },
61 { MODKEY|MOD_SHIFT, 'C', killclient, {0} },
62 { MODKEY, 'T', setlayout, {.v = &layouts[0]} },
63 { MODKEY, 'F', setlayout, {.v = &layouts[1]} },
64 { MODKEY, 'M', setlayout, {.v = &layouts[2]} },
65 { MODKEY, VK_SPACE, setlayout, {0} },
66 { MODKEY|MOD_SHIFT, VK_SPACE, togglefloating, {0} },
67 { MODKEY, 'N', toggleborder, {0} },
68 { MODKEY, 'E', toggleexplorer, {0} },
70 { MODKEY, '0', view, {.ui = ~0 } },
71 { MODKEY|MOD_SHIFT, '0', tag, {.ui = ~0 } },
72 TAGKEYS( '1', 0)
73 TAGKEYS( '2', 1)
74 TAGKEYS( '3', 2)
75 TAGKEYS( '4', 3)
76 TAGKEYS( '5', 4)
77 TAGKEYS( '6', 5)
78 TAGKEYS( '7', 6)
79 TAGKEYS( '8', 7)
80 TAGKEYS( '9', 8)
81 { MODKEY, 'Q', quit, {0} },
84 /* button definitions */
85 /* click can be a tag number (starting at 0), ClkLtSymbol, ClkStatusText or ClkWinTitle */
86 static Button buttons[] = {
87 /* click button event type modifier keys function argument */
88 { ClkLtSymbol, WM_LBUTTONDOWN, 0, setlayout, {0} },
89 { ClkLtSymbol, WM_RBUTTONDOWN, 0, setlayout, {.v = &layouts[2]} },
90 { ClkWinTitle, WM_MBUTTONDOWN, 0, zoom, {0} },
91 { ClkStatusText, WM_MBUTTONDOWN, 0, spawn, {.v = termcmd } },
92 #if 0
93 { ClkClientWin, WM_MBUTTONDOWN, MODKEY, togglefloating, {0} },
94 #endif
95 { ClkTagBar, WM_LBUTTONDOWN, 0, view, {0} },
96 { ClkTagBar, WM_RBUTTONDOWN, 0, toggleview, {0} },
97 { ClkTagBar, WM_LBUTTONDOWN, MODKEY, tag, {0} },
98 { ClkTagBar, WM_RBUTTONDOWN, MODKEY, toggletag, {0} },