My configuration of sxmo fork of suckless dwm.

git clone git://watertao.xyz/programs/sxmo-dwm.git

commit ec98b4dd2c320ebfd3b4f32d22f71a874b00017f
parent 4d86d46337c88b66e6eecec5e1e7e78795b823c5
Author: Nguyễn Gia Phong <mcsinyx@disroot.org>
Date:   Sun, 16 May 2021 22:30:53 +0700

Use Mod4 as MODKEY

Signed-off-by: Stacy Harper <contact@stacyharper.net>

Diffstat:
Mconfig.def.h | 10++++------
Mdwm.1 | 70+++++++++++++++++++++++++++++++++++-----------------------------------
2 files changed, 39 insertions(+), 41 deletions(-)

diff --git a/config.def.h b/config.def.h @@ -67,13 +67,11 @@ static const Layout layouts[] = { }; /* key definitions */ -#define MODKEY Mod1Mask +#define MODKEY Mod4Mask #define TAGKEYS(KEY,TAG) \ {0, MODKEY, KEY, view, {.ui = 1 << TAG} }, \ {0, MODKEY|ControlMask, KEY, toggleview, {.ui = 1 << TAG} }, \ - {0, MODKEY|ShiftMask, KEY, tag, {.ui = 1 << TAG} }, \ - {0, MODKEY|ControlMask|ShiftMask, KEY, toggletag, {.ui = 1 << TAG} }, \ - {0, Mod4Mask, KEY, toggletag, {.ui = 1 << TAG} }, + {0, MODKEY|ShiftMask, KEY, tag, {.ui = 1 << TAG} }, /* helper for spawning shell commands in the pre dwm-5.0 fashion */ #define SHCMD(cmd) { .v = (const char*[]){ "/bin/sh", "-c", cmd, NULL } } @@ -178,7 +176,7 @@ static Button buttons[] = { /* click event mask button function argument */ { ClkTagBar, 0, Button1, view, {0} }, { ClkLtSymbol, 0, Button1, cyclelayout, {.i = +1} }, - { ClkClientWin, Mod4Mask, Button1, movemouse, {0} }, - { ClkClientWin, Mod4Mask, Button3, resizemouse, {0} }, + { ClkClientWin, MODKEY, Button1, movemouse, {0} }, + { ClkClientWin, MODKEY, Button3, resizemouse, {0} }, }; diff --git a/dwm.1 b/dwm.1 @@ -52,114 +52,114 @@ label toggles between tiled and floating layout. .B Button3 click on a tag label adds/removes all windows with that tag to/from the view. .TP -.B Mod1\-Button1 +.B Mod4\-Button1 click on a tag label applies that tag to the focused window. .TP -.B Mod1\-Button3 +.B Mod4\-Button3 click on a tag label adds/removes that tag to/from the focused window. .SS Keyboard commands .TP -.B Mod1\-Shift\-Return +.B Mod4\-Shift\-Return Start .BR st(1). .TP -.B Mod1\-p +.B Mod4\-p Spawn .BR dmenu(1) for launching other programs. .TP -.B Mod1\-, +.B Mod4\-, Focus previous screen, if any. .TP -.B Mod1\-. +.B Mod4\-. Focus next screen, if any. .TP -.B Mod1\-Shift\-, +.B Mod4\-Shift\-, Send focused window to previous screen, if any. .TP -.B Mod1\-Shift\-. +.B Mod4\-Shift\-. Send focused window to next screen, if any. .TP -.B Mod1\-b +.B Mod4\-b Toggles bar on and off. .TP -.B Mod1\-t +.B Mod4\-t Sets tiled layout. .TP -.B Mod1\-f +.B Mod4\-f Sets floating layout. .TP -.B Mod1\-m +.B Mod4\-m Sets monocle layout. .TP -.B Mod1\-space +.B Mod4\-space Toggles between current and previous layout. .TP -.B Mod1\-Control\-, +.B Mod4\-Control\-, Cycles backwards in layout list. .TP -.B Mod1\-Control\-. +.B Mod4\-Control\-. Cycles forwards in layout list. .TP -.B Mod1\-j +.B Mod4\-j Focus next window. .TP -.B Mod1\-k +.B Mod4\-k Focus previous window. .TP -.B Mod1\-i +.B Mod4\-i Increase number of windows in master area. .TP -.B Mod1\-d +.B Mod4\-d Decrease number of windows in master area. .TP -.B Mod1\-l +.B Mod4\-l Increase master area size. .TP -.B Mod1\-h +.B Mod4\-h Decrease master area size. .TP -.B Mod1\-Return +.B Mod4\-Return Zooms/cycles focused window to/from master area (tiled layouts only). .TP -.B Mod1\-Shift\-c +.B Mod4\-Shift\-c Close focused window. .TP -.B Mod1\-Shift\-space +.B Mod4\-Shift\-space Toggle focused window between tiled and floating state. .TP -.B Mod1\-Tab +.B Mod4\-Tab Toggles to the previously selected tags. .TP -.B Mod1\-Shift\-[1..n] +.B Mod4\-Shift\-[1..n] Apply nth tag to focused window. .TP -.B Mod1\-Shift\-0 +.B Mod4\-Shift\-0 Apply all tags to focused window. .TP -.B Mod1\-Control\-Shift\-[1..n] +.B Mod4\-Control\-Shift\-[1..n] Add/remove nth tag to/from focused window. .TP -.B Mod1\-[1..n] +.B Mod4\-[1..n] View all windows with nth tag. .TP -.B Mod1\-0 +.B Mod4\-0 View all windows with any tag. .TP -.B Mod1\-Control\-[1..n] +.B Mod4\-Control\-[1..n] Add/remove all windows with nth tag to/from the view. .TP -.B Mod1\-Shift\-q +.B Mod4\-Shift\-q Quit dwm. .SS Mouse commands .TP -.B Mod1\-Button1 +.B Mod4\-Button1 Move focused window while dragging. Tiled windows will be toggled to the floating state. .TP -.B Mod1\-Button2 +.B Mod4\-Button2 Toggles focused window between floating and tiled state. .TP -.B Mod1\-Button3 +.B Mod4\-Button3 Resize focused window while dragging. Tiled windows will be toggled to the floating state. .SH CUSTOMIZATION dwm is customized by creating a custom config.h and (re)compiling the source