[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[RP] Caps_Lock is not a modifier
From: |
Rupert Levene |
Subject: |
[RP] Caps_Lock is not a modifier |
Date: |
Sun Nov 10 11:04:01 2002 |
If you do "escape Caps_Lock" then rp doesn't recognize the sequence
"Caps_Lock Caps_Lock". This is because the IsModifierKey function thinks
Caps_Lock is a modifier. (Incidentally, my xmodmap setup is such that caps lock
_doesn't_ toggle the shift lock, and it fails if this isn't the case
as well).
Ugly-as-hell fix: adjust read_key in input.c as follows:
--- ../../../ratpoison-split/ratpoison/src/input.c Wed Oct 16 14:22:11 2002
+++ input.c Sun Nov 10 18:47:59 2002
@@ -262,13 +262,15 @@
{
XEvent ev;
int nbytes;
-
+ KeySym capslock = XStringToKeysym("Caps_Lock");
+
do
{
XMaskEvent (dpy, KeyPressMask, &ev);
*modifiers = ev.xkey.state;
nbytes = cook_keycode (&ev.xkey, keysym, modifiers, keysym_name, len, 0);
- } while (IsModifierKey (*keysym));
+ PRINT_DEBUG("Got %s\n", XKeysymToString(*keysym));
+ } while (IsModifierKey (*keysym) && *keysym != capslock);
return nbytes;
}
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [RP] Caps_Lock is not a modifier,
Rupert Levene <=