2

I use vim and I mapped CapsLock to Escape. Recently I decided to switch from qwerty keyboard to Colemak keyboard layout. Colemak maps CapsLock to Backspace. How can I map CapsLock to Escape back? In Linux Mint (what I use) it is possible to change setting to define CapsLock behaviour. It works when I use qwerty, but it breaks when I switch to Colemak.

Also I tried xcape. After installing it, I added the following lines to my .profile:

setxkbmap -option 'caps:ctrl_modifier'
xcape -e 'Caps_Lock=Escape'

However, it does not map CapsLock to Escape back. Any suggestions?

ashim
  • 1,017
  • Could you edit in the output of xmodmap -pke | grep 'keycode 37'? – Alex Stragies Nov 26 '16 at 23:54
  • In Colemak, there is no caps lock key, so remapping it won't do anything. (See https://en.wikipedia.org/wiki/Keyboard_layout#Colemak) You probably want to remap your left backspace key. I've just asked a question about that here: https://unix.stackexchange.com/questions/411861/how-can-i-remap-left-backspace-to-escape-on-the-colemak-keyboard-layout?noredirect=1&lq=1 – Jonathan Dec 19 '17 at 16:58
  • @Jon the key acts like a left backspace but is in fact defined as <CAPS> in the layout; see /usr/share/X11/xkb/symbols/us. – quixotic Dec 19 '17 at 18:21

0 Answers0