I am on Ubuntu and using a Microsoft keyboard. I want to map my Win key to a Ctrl key. How can I do that?
Xorg Keyboard – How to Map ‘Windows’ Key to ‘Ctrl’
keyboardxorg
keyboardxorg
I am on Ubuntu and using a Microsoft keyboard. I want to map my Win key to a Ctrl key. How can I do that?
Best Answer
xmodmap
lets you modify keymaps. Make a file to hold xmodmap commands (~/.xmodmaprc
is a common choice). The Win keys are called "Super" in xmodmap (Super_L and Super_R for the left and right ones). By default they're connected tomod4
, so you want to remove them from that modifier and add them tocontrol
. Add this to the command file:Tell
xmodmap
to load it with:It will only last as long as your X session does, so you'll need to rerun it each time, or put it in something like
~/.xinitrc
so it will be run automatically