Is it possible to remap the CapsLock key system wide such that when the CapsLock button is pressed by itself it acts as the escape key and when pressed with another key it acts as the control key?
|
|
I have found a very good solution called xcape. From the README:
|
|||
|
|
|
I mapped Caps to Escape so that I would be more comfortable typing in Vim. I used
To apply: To map CapsLock + [another Key], consider using |
|||
|
|
|
A Linux-only solution for remapping keys system-wide is to write a simple udev rule. It won't depend on X, will work on any terminal or app and is portable between any recent Linux installs by simply copying two files. You need to write 2 files: one containing the udev rule which tells the kernel to remap the keys and one containing the actual mappings you need. Using this method I've remapped my whole keyboard, maybe the code is useful as inspiration http://git.adirat.com/carpalx-keyboard |
|||||
|
|
