From 02833a3bce0671a4ba3c43d81269f971bdb96145 Mon Sep 17 00:00:00 2001 From: JozanLeClerc Date: Sat, 7 Nov 2020 23:56:24 +0100 Subject: Added support for ^j and ^k --- dmenu.c | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/dmenu.c b/dmenu.c index 3c96e70..ae7c292 100644 --- a/dmenu.c +++ b/dmenu.c @@ -507,17 +507,14 @@ keypress(XKeyEvent *ev) case XK_g: ksym = XK_Escape; break; case XK_h: ksym = XK_BackSpace; break; case XK_i: ksym = XK_Tab; break; - case XK_j: /* fallthrough */ + case XK_j: ksym = XK_Down; break; /* fallthrough */ + case XK_k: ksym = XK_Up; break; /* fallthrough */ case XK_J: /* fallthrough */ case XK_m: /* fallthrough */ case XK_M: ksym = XK_Return; ev->state &= ~ControlMask; break; case XK_n: ksym = XK_Down; break; case XK_p: ksym = XK_Up; break; - case XK_k: /* delete right */ - text[cursor] = '\0'; - match(); - break; case XK_u: /* delete left */ insert(NULL, 0 - cursor); break; -- cgit v1.2.3