-
Notifications
You must be signed in to change notification settings - Fork 2
/
config.h.backup
350 lines (315 loc) · 19.4 KB
/
config.h.backup
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
/* __ _ _
* ___ ___ _ __ / _(_) __ _ | |__
* / __/ _ \| '_ \| |_| |/ _` | | '_ \
* | (_| (_) | | | | _| | (_| |_| | | |
* \___\___/|_| |_|_| |_|\__, (_)_| |_|
* |___/
* dwm's configuration file (yes, config file)
*/
/* appearance */
static const unsigned int borderpx = 3;
static const unsigned int snap = 6;
static const unsigned int gappih = 10;
static const unsigned int gappiv = 10;
static const unsigned int gappoh = 6;
static const unsigned int gappov = 6;
static const float mfact = 0.5; /* factor of master area */
static const int nmaster = 1; /* clients in master */
static const int nstack = 0; /* number of clients in primary stack area */
static const int resizehints = 0; /* 1 means respect size hints */
static int smartgaps = 0; /* 1 means no gap with one window */
static const int user_bh = 25; /* 0 means height equal to font size */
static const int user_tp = 5; /* 0 means default tag padding */
static const int showbar = 1; /* 0 means no bar */
static int floatposgrid_x = 5;
static int floatposgrid_y = 5;
static const int topbar = 1; /* 0 means bottom bar */
static const int attachmode = 2; /* 0 master (default), 1 = above, 2 = aside, 3 = below, 4 = bottom */
static const char *fonts[] = {"Futura Bk BT:Book:size=10", "Material Design Icons:Regular:pixelsize=14:antialias=true"};
#include "vanitygaps.c"
static char back[] = "#1C1E27";
static char fore[] = "#CACACC";
static char border[] = "#CACACC";
static char col0[] = "#6C6F93";
static char col1[] = "#E4436F";
static char col2[] = "#24E39D";
static char col3[] = "#EDA685";
static char col4[] = "#00A5AF";
static char col5[] = "#B367CF";
static char col6[] = "#00A5AF";
static char col7[] = "#CACACC";
static char col8[] = "#6C6F93";
static char col9[] = "#E4436F";
static char col10[] = "#24E39D";
static char col11[] = "#EDA685";
static char col12[] = "#00A5AF";
static char col13[] = "#B367CF";
static char col14[] = "#00A5AF";
static char col15[] = "#CACACC";
static char spotify[]= "#1FC167"; //Spotify green
/* Here is the color array. Check the 'color.h' file to see the names' */
static char *colors[][3] = {
/* fg bg border code */
[SchemeNorm] = { fore, back, back }, // \x0b
[SchemeSel] = { fore, back, border }, // \x0c
[SchemeStatus] = { fore, back, border }, // \x0d
[SchemeTagsSel] = { border, back, border }, // \x0e
[SchemeTagsNorm] = { fore, back, border }, // \x0f
[SchemeInfoSel] = { fore, back, border }, // \x10
[SchemeInfoNorm] = { fore, back, border }, // \x11
[SchemeCol1] = { col1, back, col0 }, // \x12
[SchemeCol2] = { col2, back, col0 }, // \x13
[SchemeCol3] = { col3, back, col0 }, // \x14
[SchemeCol4] = { col4, back, col0 }, // \x15
[SchemeCol5] = { col5, back, col0 }, // \x16
[SchemeCol6] = { col6, back, col0 }, // \x17
[SchemeCol7] = { col7, back, col0 }, // \x18
[SchemeCol8] = { col8, back, col0 }, // \x19
[SchemeCol9] = { col9, back, col0 }, // \x1a
[SchemeCol10] = { col10, back, col0 }, // \x1b
[SchemeCol11] = { col11, back, col0 }, // \x1c
[SchemeCol12] = { spotify, back, col0 }, // \x1d
};
/* Here's the alpha array, needed to have nice transparency */
static const unsigned int baralpha = 255; //The alpha channel
static const unsigned int borderalpha = OPAQUE; // The border alpha channel
static const unsigned int alphas[][3] = {
/* fg bg border */
[SchemeNorm] = { OPAQUE, baralpha, borderalpha },
[SchemeSel] = { OPAQUE, baralpha, borderalpha },
[SchemeStatus] = { OPAQUE, baralpha, borderalpha },
[SchemeTagsSel] = { OPAQUE, baralpha, borderalpha },
[SchemeTagsNorm] = { OPAQUE, baralpha, borderalpha },
[SchemeInfoSel] = { OPAQUE, baralpha, borderalpha },
[SchemeInfoNorm] = { OPAQUE, baralpha, borderalpha },
[SchemeCol1] = { OPAQUE, baralpha, borderalpha },
[SchemeCol2] = { OPAQUE, baralpha, borderalpha },
[SchemeCol3] = { OPAQUE, baralpha, borderalpha },
[SchemeCol4] = { OPAQUE, baralpha, borderalpha },
[SchemeCol5] = { OPAQUE, baralpha, borderalpha },
[SchemeCol6] = { OPAQUE, baralpha, borderalpha },
[SchemeCol7] = { OPAQUE, baralpha, borderalpha },
[SchemeCol8] = { OPAQUE, baralpha, borderalpha },
[SchemeCol9] = { OPAQUE, baralpha, borderalpha },
[SchemeCol10] = { OPAQUE, baralpha, borderalpha },
[SchemeCol11] = { OPAQUE, baralpha, borderalpha },
[SchemeCol12] = { OPAQUE, baralpha, borderalpha },
};
/* tagging */
/* tagging: refer to https://github.com/bakkeby/patches/wiki/tagicons */
static const char *tags[NUMTAGS] = { NULL }; /* left for compatibility reasons, i.e. code that checks LENGTH(tags) */
static char *tagicons[][NUMTAGS] = {
[IconsDefault] = { "", "", "", "", "", "" },
[IconsVacant] = { NULL },
[IconsOccupied] = { "", "", "", "", "", "" },
};
static const Rule rules[] = {
/* xprop(1):
* WM_CLASS(STRING) = instance, class
* WM_NAME(STRING) = title
*/
/* class instance title tags mask isfloating floatpos monitor */
{ "Gimp", NULL, NULL, 0, 1, NULL, -1 },
{ "mpv", NULL, NULL, 0, 1, NULL, -1 },
{ "lxappareance", NULL, NULL, 0, 1, NULL, -1 },
{ "Pavucontrol", NULL, NULL, 0, 1, NULL, -1 },
{ "qt5ct", NULL, NULL, 0, 1, NULL, -1 },
{ "Gucharmap", NULL, NULL, 0, 1, NULL, -1 },
{ "Sxiv", NULL, NULL, 0, 1, NULL, -1 },
{ "kruler", NULL, NULL, 0, 1, NULL, -1 },
{ "zoom", NULL, NULL, 0, 1, NULL, -1 },
{ "Connman-gtk", NULL, NULL, 0, 1, NULL, -1 },
{ "Alacritty", "calendar.txt", NULL, 0, 1, NULL, -1 },
};
/* layout(s) */
#define FORCE_VSPLIT 1 /* nrowgrid layout: force two clients to always split vertically */
/* Here's the layouts. The count starts with zero */
static const Layout layouts[] = {
/* symbol arrange function
{ "", tile },
{ "", centeredmaster },
{ "", gaplessgrid },
{ "[M]", monocle },
{ "[D]", deck },
{ NULL, NULL }, */
/* symbol arrange function, { nmaster, nstack, layout, master axis, stack axis, secondary stack axis } */
{ "", flextile, { -1, -1, SPLIT_VERTICAL, TOP_TO_BOTTOM, TOP_TO_BOTTOM, 0, NULL } }, // default tile layout
{ "", flextile, { -1, -1, SPLIT_VERTICAL, TOP_TO_BOTTOM, GAPPLESSGRID_ALT1, 0, NULL } }, // default tile layout
{ "", flextile, { -1, -1, SPLIT_CENTERED_VERTICAL, TOP_TO_BOTTOM, TOP_TO_BOTTOM, 0, NULL } }, // centeredmaster
{ "", flextile, { -1, -1, NO_SPLIT, GAPPLESSGRID, 0, 0, NULL } }, // gappless grid
{ NULL, NULL, {0} },
};
static const Layout doublestack[] = {
{ "|[D][D]", flextile, { -1, -1, SPLIT_VERTICAL_DUAL_STACK, TOP_TO_BOTTOM, MONOCLE, MONOCLE, NULL } }, // 2 stacks, both monocle
{ "|[|][|]", flextile, { -1, -1, SPLIT_VERTICAL_DUAL_STACK, TOP_TO_BOTTOM, LEFT_TO_RIGHT, LEFT_TO_RIGHT, NULL } }, // two stack, both horizontal
{ "|[D][|]", flextile, { -1, -1, SPLIT_VERTICAL_DUAL_STACK, TOP_TO_BOTTOM, MONOCLE, LEFT_TO_RIGHT, NULL } }, // two stack, monocle and horizontal
{ "|[|][D]", flextile, { -1, -1, SPLIT_VERTICAL_DUAL_STACK, TOP_TO_BOTTOM, LEFT_TO_RIGHT, MONOCLE, NULL } }, // two stack, horizontal and monocle
};
static const Layout full[] = {
{ "[M]", flextile, { -1, -1, NO_SPLIT, MONOCLE, 0, 0, monoclesymbols } }, // monocle
{ "[D]", flextile, { -1, -1, SPLIT_VERTICAL, TOP_TO_BOTTOM, MONOCLE, 0, NULL } }, // deck
};
/* key definitions */
#define MODKEY Mod4Mask
#define TAGKEYS(KEY,TAG) \
{ MODKEY, KEY, view, {.ui = 1 << TAG} }, \
{ MODKEY|Mod1Mask, KEY, toggleview, {.ui = 1 << TAG} }, \
{ MODKEY|ShiftMask, KEY, tag, {.ui = 1 << TAG} }, \
{ MODKEY|ControlMask, KEY, toggletag, {.ui = 1 << TAG} },
/*
* Xresources preferences to load at startup
*/
ResourcePref resources[] = {
{ "back", STRING, &back },
{ "fore", STRING, &fore },
{ "cursorColor", STRING, &border },
{ "col0", STRING, &col0 },
{ "col1", STRING, &col1 },
{ "col2", STRING, &col2 },
{ "col3", STRING, &col3 },
{ "col4", STRING, &col4 },
{ "col5", STRING, &col5 },
{ "col6", STRING, &col6 },
{ "col7", STRING, &col7 },
{ "col8", STRING, &col8 },
{ "col9", STRING, &col9 },
{ "col10", STRING, &col10 },
{ "col11", STRING, &col11 },
{ "col12", STRING, &col12 },
{ "col13", STRING, &col13 },
{ "col14", STRING, &col14 },
{ "col15", STRING, &col15 },
};
/* keybindings! Here's only the dwm-related keybindings. To launch apps I use sxhkd */
#include "movestack.c"
#include "shiftview.c"
//#include "inplacerotate.c"
static Key keys[] = {
/* modifier key function argument */
/*About windows */
{ MODKEY|ShiftMask, XK_q, killclient, {0} },
{ MODKEY, XK_j, focusstack, {.i = +1 } },
{ MODKEY, XK_k, focusstack, {.i = -1 } },
{ MODKEY|ControlMask, XK_j, inplacerotate, {.i = +1} },
{ MODKEY|ControlMask, XK_k, inplacerotate, {.i = -1} },
{ MODKEY|ShiftMask, XK_g, zoom, {0} }, //send window to master
{ MODKEY, XK_g, switchcol, {0} }, //swap focus between master and stack
{ MODKEY, XK_h, setmfact, {.f = -0.02} }, // Shrink master
{ MODKEY, XK_l, setmfact, {.f = +0.02} }, //Grow master
{ MODKEY|ControlMask, XK_comma, incnmaster, {.i = +1 } },
{ MODKEY|ControlMask, XK_period, incnmaster, {.i = -1 } },
{ MODKEY|ShiftMask, XK_j, movestack, {.i = +1 } },
{ MODKEY|ShiftMask, XK_k, movestack, {.i = -1 } },
/* About tags (desktops) */
{ MODKEY, XK_Tab, view, {0} }, // Prev tag
{ MODKEY, XK_0, view, {.ui = ~0 } }, // View all tags
{ MODKEY, XK_0, setlayout, {.v = &layouts[2]} }, // Grid for all tags
{ MODKEY|ShiftMask, XK_0, tag, {.ui = ~0 } }, // Window on all tags
{ MODKEY|ShiftMask, XK_o, winview, {0} }, //follow window on viewall
{ MODKEY|ShiftMask, XK_o, setlayout, {.v = &layouts[0]} }, /*tiled*/
{ MODKEY|ControlMask, XK_l, shiftview, { .i = +1 } }, // Next tag
{ MODKEY|ControlMask, XK_h, shiftview, { .i = -1 } }, // prev tag
TAGKEYS( XK_1, 0) /*Activate tag 1*/
TAGKEYS( XK_2, 1) /*Activate tag 2*/
TAGKEYS( XK_3, 2) /*Activate tag 3*/
TAGKEYS( XK_4, 3) /*Activate tag 4*/
TAGKEYS( XK_5, 4) /*Activate tag 5*/
TAGKEYS( XK_6, 5) /*Activate tag 6*/
/*About layouts*/
{ MODKEY|ControlMask, XK_m, setlayout, {.v = &doublestack[0]} }, /*double deck*/
{ MODKEY|ControlMask, XK_i, setlayout, {.v = &doublestack[2]} }, /*up decked*/
{ MODKEY|ControlMask, XK_u, setlayout, {.v = &doublestack[3]} }, /*down decked*/
{ MODKEY|ControlMask, XK_o, setlayout, {.v = &doublestack[1]} }, /*stack grid*/
{ MODKEY, XK_t, setlayout, {.v = &layouts[0]} }, // Grid for all tags
{ MODKEY, XK_m, setlayout, {.v = &full[0]} }, // Grid for all tags
{ MODKEY|ShiftMask, XK_m, setlayout, {.v = &full[1]} }, // Grid for all tags
{ MODKEY, XK_s, togglefloating, {0} },
{ MODKEY, XK_F11, togglefullscreen, {0} },
{ MODKEY|ShiftMask, XK_F11, togglefakefullscreen, {0} }, // Fullscreen on the tile
{ MODKEY|Mod1Mask, XK_comma, cyclelayout, {.i = -1 } },
{ MODKEY|Mod1Mask, XK_period, cyclelayout, {.i = +1 } },
/*About monitors*/
{ MODKEY, XK_comma, focusmon, {.i = -1 } },
{ MODKEY, XK_period, focusmon, {.i = +1 } },
{ MODKEY|ShiftMask, XK_comma, tagmon, {.i = -1 } },
{ MODKEY|ShiftMask, XK_period, tagmon, {.i = +1 } },
//{ MODKEY|Mod1Mask|ControlMask, XK_comma, tagswapmon, {.i = +1 } }, // Intercambiar con monitor izquierdo
//{ MODKEY|Mod1Mask|ControlMask, XK_period, tagswapmon, {.i = -1 } }, // intercambiar con monitor derecho
/* dwm especifico*/
{ MODKEY, XK_b, togglebar, {0} },
{ MODKEY|Mod1Mask, XK_l, setcfact, {.f = +0.25} }, // Grow stack
{ MODKEY|Mod1Mask, XK_h, setcfact, {.f = -0.25} }, // Shrink stack
{ MODKEY|Mod1Mask, XK_o, setcfact, {.f = 0.00} }, // Reset stack
{ MODKEY, XK_F8, xrdb, {.v = NULL } },
/* About gaps */
{ MODKEY|Mod1Mask, XK_u, incrgaps, {.i = +1 } },
{ MODKEY|Mod1Mask|ShiftMask, XK_u, incrgaps, {.i = -1 } },
//{ MODKEY|Mod1Mask, XK_i, incrigaps, {.i = +1 } },
//{ MODKEY|Mod1Mask|ShiftMask, XK_i, incrigaps, {.i = -1 } },
//{ MODKEY|Mod1Mask, XK_o, incrogaps, {.i = +1 } },
//{ MODKEY|Mod1Mask|ShiftMask, XK_o, incrogaps, {.i = -1 } },
{ MODKEY|Mod1Mask, XK_0, togglegaps, {0} },
{ MODKEY|Mod1Mask|ShiftMask, XK_0, defaultgaps, {0} },
//{ MODKEY|Mod1Mask, XK_6, incrihgaps, {.i = +1 } },
//{ MODKEY|Mod1Mask|ShiftMask, XK_6, incrihgaps, {.i = -1 } },
//{ MODKEY|Mod1Mask, XK_7, incrivgaps, {.i = +1 } },
//{ MODKEY|Mod1Mask|ShiftMask, XK_7, incrivgaps, {.i = -1 } },
//{ MODKEY|Mod1Mask, XK_8, incrohgaps, {.i = +1 } },
//{ MODKEY|Mod1Mask|ShiftMask, XK_8, incrohgaps, {.i = -1 } },
//{ MODKEY|Mod1Mask, XK_9, incrovgaps, {.i = +1 } },
//{ MODKEY|Mod1Mask|ShiftMask, XK_9, incrovgaps, {.i = -1 } },
{ MODKEY, XK_z, scratchpad_show, {0} },
{ MODKEY|Mod1Mask, XK_z, scratchpad_hide, {0} },
{ MODKEY|ControlMask, XK_z, scratchpad_remove,{0} },
{ MODKEY|ControlMask, XK_i, incnstack, {.i = +1 } },
{ MODKEY|ControlMask, XK_o, incnstack, {.i = -1 } },
{ MODKEY|ControlMask, XK_q, rotatelayoutaxis, {.i = +1 } }, /* flextile, 1 = layout axis */
{ MODKEY|ControlMask|ShiftMask, XK_q, rotatelayoutaxis, {.i = -1 } }, /* flextile, 1 = layout axis */
{ MODKEY|ControlMask, XK_plus, rotatelayoutaxis, {.i = +2 } }, /* flextile, 2 = master axis */
{ MODKEY|ControlMask, XK_dead_acute, rotatelayoutaxis, {.i = -2 } }, /* flextile, 2 = master axis */
{ MODKEY, XK_plus, rotatelayoutaxis, {.i = +3 } }, /* flextile, 3 = stack axis */
{ MODKEY, XK_dead_acute, rotatelayoutaxis, {.i = -3 } }, /* flextile, 3 = stack axis */
{ MODKEY|Mod1Mask, XK_plus, rotatelayoutaxis, {.i = +4 } }, /* flextile, 4 = secondary stack axis */
{ MODKEY|Mod1Mask, XK_dead_acute, rotatelayoutaxis, {.i = -4 } }, /* flextile, 4 = secondary stack axis */
{ MODKEY, XK_bar, mirrorlayout, {0} }, /* flextile, flip master and stack areas */
};
/* button definitions */
/* click can be ClkTagBar, ClkLtSymbol, ClkStatusText, ClkWinTitle, ClkClientWin, or ClkRootWin */
static Button buttons[] = {
/* click event mask button function argument */
{ ClkLtSymbol, 0, Button1, cyclelayout, {.i = +1 } },
{ ClkLtSymbol, 0, Button3, setlayout, {.v = &layouts[5]} },
{ ClkWinTitle, 0, Button2, zoom, {0} },
{ ClkStatusText, 0, Button1, sigdwmblocks, {.i = 1} },
{ ClkStatusText, 0, Button2, sigdwmblocks, {.i = 2} },
{ ClkStatusText, 0, Button3, sigdwmblocks, {.i = 3} },
{ ClkClientWin, MODKEY, Button1, movemouse, {0} },
{ ClkClientWin, MODKEY, Button2, togglefloating, {0} },
{ ClkClientWin, MODKEY, Button3, resizemouse, {0} },
{ ClkClientWin, MODKEY|ShiftMask, Button3, dragcfact, {0} },
{ ClkTagBar, 0, Button1, view, {0} },
{ ClkTagBar, 0, Button3, toggleview, {0} },
{ ClkTagBar, MODKEY, Button1, tag, {0} },
{ ClkTagBar, MODKEY, Button3, toggletag, {0} },
{ ClkTagBar, 0, Button4, cycleiconset, {.i = +1 } },
{ ClkTagBar, 0, Button5, cycleiconset, {.i = -1 } },
{ ClkClientWin, MODKEY, Button1, winview, {0} },
};
static const char *ipcsockpath = "/tmp/dwm.sock";
static IPCCommand ipccommands[] = {
IPCCOMMAND( view, 1, {ARG_TYPE_UINT} ),
IPCCOMMAND( toggleview, 1, {ARG_TYPE_UINT} ),
IPCCOMMAND( tag, 1, {ARG_TYPE_UINT} ),
IPCCOMMAND( toggletag, 1, {ARG_TYPE_UINT} ),
IPCCOMMAND( tagmon, 1, {ARG_TYPE_UINT} ),
IPCCOMMAND( focusmon, 1, {ARG_TYPE_SINT} ),
IPCCOMMAND( focusstack, 1, {ARG_TYPE_SINT} ),
IPCCOMMAND( zoom, 1, {ARG_TYPE_NONE} ),
IPCCOMMAND( incnmaster, 1, {ARG_TYPE_SINT} ),
IPCCOMMAND( killclient, 1, {ARG_TYPE_SINT} ),
IPCCOMMAND( togglefloating, 1, {ARG_TYPE_NONE} ),
IPCCOMMAND( setmfact, 1, {ARG_TYPE_FLOAT} ),
IPCCOMMAND( setlayoutsafe, 1, {ARG_TYPE_PTR} ),
IPCCOMMAND( quit, 1, {ARG_TYPE_NONE} ),
IPCCOMMAND( xrdb, 1, {ARG_TYPE_NONE} )
};