summaryrefslogtreecommitdiff
path: root/desktop
diff options
context:
space:
mode:
authorDave Woodfall <dave@slackbuilds.org>2019-06-13 08:38:17 +0100
committerWilly Sudiarto Raharjo <willysr@slackbuilds.org>2019-06-15 08:12:46 +0700
commit940e4ca75735c85ee9f842744684b5cf54fc6669 (patch)
tree99accc492b9b24a3695700aecb468110fd14c7a2 /desktop
parent2f8dd5a50fb81c701fb8e1c31f97c31645d3f26c (diff)
downloadslackbuilds-940e4ca75735c85ee9f842744684b5cf54fc6669.tar.gz
desktop/dwm: Add option to use keypad to select tags.
Diffstat (limited to 'desktop')
-rw-r--r--desktop/dwm/README4
-rw-r--r--desktop/dwm/dwm.SlackBuild5
-rw-r--r--desktop/dwm/sbo-patches/enable-keypad.patch19
3 files changed, 27 insertions, 1 deletions
diff --git a/desktop/dwm/README b/desktop/dwm/README
index 64d2e2e699..f02b1fec01 100644
--- a/desktop/dwm/README
+++ b/desktop/dwm/README
@@ -31,6 +31,10 @@ Use rofi instead of dmenu:
ROFI=yes sh dwm.SlackBuild
+Enable keypad for tags as well as top row digits:
+
+ KEYPAD=yes sh dwm.SlackBuild
+
The ROFI option also installs dwm.rasi rofi theme to
/usr/share/rofi/themes. This is set to use the same
font as dwm, so if you have patched the dwm font then you
diff --git a/desktop/dwm/dwm.SlackBuild b/desktop/dwm/dwm.SlackBuild
index 82e636191b..06a0579171 100644
--- a/desktop/dwm/dwm.SlackBuild
+++ b/desktop/dwm/dwm.SlackBuild
@@ -37,7 +37,7 @@
PRGNAM=dwm
VERSION=${VERSION:-6.2}
-BUILD=${BUILD:-4}
+BUILD=${BUILD:-5}
TAG=${TAG:-_SBo}
if [ -z "$ARCH" ]; then
@@ -89,6 +89,9 @@ MOD4=${MOD4:-no}
ROFI=${ROFI:-no}
[ "$ROFI" = "yes" ] && patch -p1 <$CWD/sbo-patches/replace-dmenu-rofi.patch
+KEYPAD=${KEYPAD:-no}
+[ "$KEYPAD" = "yes" ] && patch -p0 <$CWD/sbo-patches/enable-keypad.patch
+
mv config.def.h config.h
chown -R root:root .
diff --git a/desktop/dwm/sbo-patches/enable-keypad.patch b/desktop/dwm/sbo-patches/enable-keypad.patch
new file mode 100644
index 0000000000..8341b12fd9
--- /dev/null
+++ b/desktop/dwm/sbo-patches/enable-keypad.patch
@@ -0,0 +1,19 @@
+--- config.def.h 2019-06-04 20:24:48.426235490 +0100
++++ config.h 2019-06-13 08:17:45.674540960 +0100
+@@ -84,6 +84,16 @@
+ { MODKEY, XK_period, focusmon, {.i = +1 } },
+ { MODKEY|ShiftMask, XK_comma, tagmon, {.i = -1 } },
+ { MODKEY|ShiftMask, XK_period, tagmon, {.i = +1 } },
++ TAGKEYS( XK_KP_End, 0)
++ TAGKEYS( XK_KP_Down, 1)
++ TAGKEYS( XK_KP_Next, 2)
++ TAGKEYS( XK_KP_Left, 3)
++ TAGKEYS( XK_KP_Begin, 4)
++ TAGKEYS( XK_KP_Right, 5)
++ TAGKEYS( XK_KP_Home, 6)
++ TAGKEYS( XK_KP_Up, 7)
++ TAGKEYS( XK_KP_Prior, 8)
++ TAGKEYS( XK_KP_Insert, 9)
+ TAGKEYS( XK_1, 0)
+ TAGKEYS( XK_2, 1)
+ TAGKEYS( XK_3, 2)