I'm experiencing a strange behavior with xmodmap.
I want to remap Caps_Lock
so it acts as Escape
and Shift+Caps_Lock
so it acts as Caps_Lock
.
In my ~/.Xmodmap
i tried every possible combination of the following commands always with the same result:
clear Lock
remove Lock = Caps_Lock
keycode 66 =
keycode 66 = Escape Caps_Lock
keysym Caps_Lock = Escape Caps_Lock
The Caps_Lock
gets properly remapped to Escape
$ xmodmap -pke | grep Caps
keycode 66 = Escape Caps_Lock Escape Caps_Lock
BUT after reboot it still does lock CAPS. So it acts as both Escape
and Caps_Lock
.
Running xev i can see that the state
switches between 0x10
and 0x12
.
While Shift+Caps_Lock
works as expected (as Caps_Lock
).
If i run xmodmap ~/.Xmodmap
in my terminal after logging in i get this as before:
$ xmodmap -pke | grep Caps
keycode 66 = Escape Caps_Lock Escape Caps_Lock
BUT Caps_Lock
starts behaving as expected, only as Escape
and does no longer lock CAPS.
I really dont get what am i doing wrong.