Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

I have a laptop that has KP_Home and KP_End functionality for the KP_7 and KP_1 keys, respectively. However, the current behavior is as follows (for KP_Home only):

No Mods:          KP_Home
Shift:            KP_7
Num_Lock:         KP_7
Shift + Num_Lock: KP_Home

I'm trying to use xmodmap to remap it so it's always KP_Home if Num_Lock is off, and always KP_7 if Num_Lock is on. However, if I remap the current config from:

keycode  79 = KP_Home KP_7 KP_Home KP_7

to:

keycode  79 = KP_Home KP_Home KP_7 KP_7 KP_7 KP_7

It treats the key as if it is always KP_Home. X11 seems to be really weird with the Num_Lock modifier because it'll only look at the first two keysyms for a given line, and it will ONLY swap the two during Num_Lock if they are both KP_* keysyms. If I remap the key to "A" and "B", it will not swap the two even with the Num_Lock modifier.

How can I remap my numpad to behave properly with Num_Lock on, regardless of shift behavior?

share|improve this question
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Browse other questions tagged or ask your own question.