[wiki] [sites] [slock][patch][terminalkeys] Update patch to newest slock version 1.4 || Matthias Schoth

From: <git_AT_suckless.org>
Date: Sat, 16 May 2020 02:10:09 +0200

commit 03869813a4e47709b5cac33768a36d28469ee15e
Author: Matthias Schoth <mschoth_AT_gmail.com>
Date: Sat May 16 02:08:19 2020 +0200

    [slock][patch][terminalkeys] Update patch to newest slock version 1.4

diff --git a/tools.suckless.org/slock/patches/terminalkeys/index.md b/tools.suckless.org/slock/patches/terminalkeys/index.md
index 6fc26d67..852f1253 100644
--- a/tools.suckless.org/slock/patches/terminalkeys/index.md
+++ b/tools.suckless.org/slock/patches/terminalkeys/index.md
_AT_@ -19,6 +19,7 @@ Mappings:
 Download
 --------
 * [slock-terminalkeys-20160618-65b8d52.diff](slock-terminalkeys-20160618-65b8d52.diff)
+* [slock-terminalkeys-1.4.diff](slock-terminalkeys-1.4.diff)
 
 Authors
 -------
diff --git a/tools.suckless.org/slock/patches/terminalkeys/slock-terminalkeys-1.4.diff b/tools.suckless.org/slock/patches/terminalkeys/slock-terminalkeys-1.4.diff
new file mode 100644
index 00000000..c8d0a45d
--- /dev/null
+++ b/tools.suckless.org/slock/patches/terminalkeys/slock-terminalkeys-1.4.diff
_AT_@ -0,0 +1,40 @@
+From 4b6b51100fa14256753f663c93daeb0f89f0a65a Mon Sep 17 00:00:00 2001
+From: Matthias Schoth <mschoth_AT_gmail.com>
+Date: Fri, 15 May 2020 22:10:27 +0200
+Subject: [PATCH] Add key commands that are commonly used in terminal
+ applications to slock.
+
+---
+ slock.c | 16 ++++++++++++++++
+ 1 file changed, 16 insertions(+)
+
+diff --git a/slock.c b/slock.c
+index d2f0886..bf1a392 100644
+--- a/slock.c
++++ b/slock.c
+_AT_@ -156,6 +156,22 @@ readpw(Display *dpy, struct xrandr *rr, struct lock **locks, int nscreens,
+ IsPFKey(ksym) ||
+ IsPrivateKeypadKey(ksym))
+ continue;
++ if (ev.xkey.state & ControlMask) {
++ switch (ksym) {
++ case XK_u:
++ ksym = XK_Escape;
++ break;
++ case XK_m:
++ ksym = XK_Return;
++ break;
++ case XK_j:
++ ksym = XK_Return;
++ break;
++ case XK_h:
++ ksym = XK_BackSpace;
++ break;
++ }
++ }
+ switch (ksym) {
+ case XK_Return:
+ passwd[len] = '+--
+2.26.2
+
Received on Sat May 16 2020 - 02:10:09 CEST

This archive was generated by hypermail 2.3.0 : Sat May 16 2020 - 02:12:49 CEST