Remap Esc to Caps Lock after mapping Caps Lock to Ctrl and Esc with xcape
1
vote
1
answer
3226
views
I currently have Caps Lock mapped to Ctrl when held and Esc when tapped (for vim) via these commands in
.xinitrc
setxkbmap -option 'caps:ctrl_modifier'
xcape -e 'Caps_Lock=Escape'
This works, but leaves me without Caps Lock so I want to remap Esc to Caps Lock.
I've tried setting it with xmodmap -e 'keycode 9 = Caps_Lock'
but that overrides the mapping on the Caps Lock key as well.
Is there any way to achieve these mappings?
Caps Lock -> Ctrl and Esc
Esc -> Caps Lock
Asked by hopibel
(130 rep)
Feb 15, 2017, 05:42 AM
Last activity: Feb 15, 2017, 09:32 AM
Last activity: Feb 15, 2017, 09:32 AM