[xmonad] xmonad and remapping keys with xmodmap
Ico
xmonad at zevv.nl
Fri Jan 18 12:19:05 CET 2013
I've recenly bought a new notebook that comes with a numeric keypad. I
don't like numeric keypads, so I remapped the keys to generate the
regular key codes for arrow keys, home, end, pgup and pgdown, etc
xmodmap -e "keycode 83 = Left Left"
...
In my xmonad.hs I use alt-shift-<arrows> for shrinking and expanding
windows:
((modMask .|. shiftMask, xK_Left ), sendMessage Shrink)
...
but when remapping strange things happen:
- using the default keyboard layout, the normal arrow keys work with
xmonad, but the numpad arrows do not ('KP_Left' is sent instead of
'Left', so that is to be expected)
- I remap the numpad arrows to send 'Left' instead of KP_Left':
xmodmap -e "keycode 83 = Left Left"
...
- Xmonad now works with the keypad left arrow key, but the normal arrow
key (that was not remapped) is no longer picked up by xmonad. It works
for all other apps I tested, though. xev shows the normal key symbols
when pressing the keys.
Any advice on how to debug of fix this is much appreciated,
Ico
--
:wq
^X^Cy^K^X^C^C^C^C
More information about the xmonad
mailing list