You are not logged in.
I want to swap the CTRL-key for the Escape-key.
How do I do it?
Offline
Use xmodmap(1)
http://www.emacswiki.org/emacs/MovingTheCtrlKey
Once you set up ~/.xmodmap you can add this line to the end of ~/.config/openbox/autostart
xmodmap ~/.xmodmap
Offline
a. some reading;
http://vim.wikia.com/wiki/Avoid_the_escape_key
b. ask the freenode/#vim people.
c. ctrl+c works to break out of insert mode by default in vim, but
http://unix.stackexchange.com/questions … hing-in-vi
Last edited by brontosaurusrex (2015-11-18 10:53:28)
Offline
Head_on_Stick, the link you have given links to a page dealing with an Emacs problem. I don't want to switch the CTRL-key with the CAPS-lock key.
So that won't do. I am still searching.
Offline
Head_on_Stick, the link you have given links to a page dealing with an Emacs problem. I don't want to switch the CTRL-key with the CAPS-lock key.
So that won't do. I am still searching.
Read xmodmap(1)
It has an option for "Escape" so try substituting that for "Control_L" in the example in my link.
xmodmap(1) is a low-level tool that would work in vim as well as EMACS
Offline
Thank you for answering. Lately I have been so busy that I haven't had the chance to make it actually happen.
But you are right. The script could also work in my case. I will let you know if it worked.
Offline
I figured it out and I made a small dance of satisfaction. Here it is:
You will have to work with keycodes so run the command:
xev
This command gave me the keycodes:
Caps_Lock = keycode 66
Escape = keycode 9
You will have to switch off Caps_Lock first by using the clear-command. Then switch it on later on.
This is how the .xmodmap finally looks like:
!
! Caps_Lock = keycode 66
! Escape = keycode 9
!
clear Lock
keycode 66 = Escape
keycode 9 = Caps_Lock
add Lock = Caps_Lock
Add this line to the end of ~/.config/openbox/autostart
xmodmap ~/.xmodmap
Reboot your computer and done!
And again, thank you for your answers.
Last edited by CooKiECruNChEr43 (2015-12-20 18:15:10)
Offline
I figured it out and I made a small dance of satisfaction
Good work, thanks for posting your solution!
Offline