Created
October 14, 2025 21:35
-
-
Save sepisoad/907d89899e1ce7ee5b2c7c9f6867e6f1 to your computer and use it in GitHub Desktop.
dwm config.h
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| static const unsigned int borderpx = 1; /* border pixel of windows */ | |
| static const unsigned int snap = 1; /* snap pixel */ /* 32 */ | |
| static const int showbar = 1; /* 0 means no bar */ | |
| static const int topbar = 0; /* 0 means bottom bar */ | |
| static const char* fonts[] = { "Hack:pixelsize=16:antialias=true:autohint=true" }; | |
| static const char dmenufont[] = "Hack:pixelsize=16:antialias=true:autohint=true"; | |
| static const char col_gray1[] = "#222222"; | |
| static const char col_gray2[] = "#444444"; | |
| static const char col_gray3[] = "#bbbbbb"; | |
| static const char col_gray4[] = "#eeeeee"; | |
| static const char col_cyan[] = "#005577"; | |
| static const char col_orange[] = "#F54927"; | |
| static const char* colors[][3] = { | |
| [SchemeNorm] = { col_gray3, col_gray1, col_cyan }, | |
| [SchemeSel] = { col_gray4, col_cyan, col_orange }, | |
| }; | |
| static const char* tags[] = { "1", "2", "3", "4", "5", "6", "7", "8", "9" }; | |
| static const Rule rules[] = { | |
| { "Gimp", NULL, NULL, 0, 1, -1 }, | |
| { "Firefox", NULL, NULL, 1 << 8, 0, -1 }, | |
| }; | |
| static const float mfact = 0.5; | |
| static const int nmaster = 1; | |
| static const int resizehints = 1; | |
| static const int lockfullscreen = 1; | |
| static const int refreshrate = 120; | |
| static const Layout layouts[] = { | |
| { "[=]", tile }, | |
| { "[~]", NULL }, | |
| { "[*]", monocle }, | |
| }; | |
| #define MODKEY Mod1Mask | |
| // #define MODKEY Mod4Mask | |
| #define TAGKEYS(KEY,TAG) \ | |
| { MODKEY, KEY, view, {.ui = 1 << TAG} }, \ | |
| { MODKEY|ShiftMask, KEY, tag, {.ui = 1 << TAG} }, | |
| #define SHCMD(cmd) { .v = (const char*[]){ "/bin/sh", "-c", cmd, NULL } } | |
| static char dmenumon[2] = "0"; | |
| static const char* dmenucmd[] = { "dmenu_run", "-m", dmenumon, "-fn", dmenufont, "-nb", col_gray1, "-nf", col_gray3, "-sb", col_cyan, "-sf", col_gray4, NULL }; | |
| static const char* termcmd[] = { "st", NULL }; | |
| static const Key keys[] = { | |
| // { MODKEY, XK_backslash, XK_p, spawn, {.v = dmenucmd } }, | |
| { MODKEY, XK_p, spawn, {.v = dmenucmd } }, | |
| { MODKEY, XK_Return, spawn, {.v = termcmd } }, | |
| { MODKEY, XK_b, togglebar, {0} }, | |
| { MODKEY, XK_comma, focusstack, {.i = +1 } }, | |
| { MODKEY, XK_period, focusstack, {.i = -1 } }, | |
| { MODKEY|ShiftMask, XK_comma, movestack, {.i = +1 } }, | |
| { MODKEY|ShiftMask, XK_period, movestack, {.i = -1 } }, | |
| { MODKEY, XK_minus, setmfact, {.f = -0.05} }, | |
| { MODKEY, XK_equal, setmfact, {.f = +0.05} }, | |
| { MODKEY|ShiftMask, XK_q, killclient, {0} }, | |
| { MODKEY, XK_t, setlayout, {.v = &layouts[0]} }, | |
| { MODKEY, XK_f, setlayout, {.v = &layouts[1]} }, | |
| { MODKEY, XK_m, setlayout, {.v = &layouts[2]} }, | |
| TAGKEYS(XK_1, 0) | |
| TAGKEYS(XK_2, 1) | |
| TAGKEYS(XK_3, 2) | |
| TAGKEYS(XK_4, 3) | |
| TAGKEYS(XK_5, 4) | |
| TAGKEYS(XK_6, 5) | |
| TAGKEYS(XK_7, 6) | |
| TAGKEYS(XK_8, 7) | |
| TAGKEYS(XK_9, 8) | |
| }; | |
| static const Button buttons[] = { | |
| { ClkLtSymbol, 0, Button1, setlayout, {0} }, | |
| { ClkLtSymbol, 0, Button3, setlayout, {.v = &layouts[2]} }, | |
| { ClkWinTitle, 0, Button2, zoom, {0} }, | |
| { ClkStatusText, 0, Button2, spawn, {.v = termcmd } }, | |
| { ClkClientWin, MODKEY, Button1, movemouse, {0} }, | |
| { ClkClientWin, MODKEY, Button2, togglefloating, {0} }, | |
| { ClkClientWin, MODKEY, Button3, resizemouse, {0} }, | |
| { ClkTagBar, 0, Button1, view, {0} }, | |
| { ClkTagBar, 0, Button3, toggleview, {0} }, | |
| { ClkTagBar, MODKEY, Button1, tag, {0} }, | |
| { ClkTagBar, MODKEY, Button3, toggletag, {0} }, | |
| }; | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment