kota.nz notes vids pics code about
Capslock is a useless key so I figured I’d reassign it to something useful. There are three ways to change a keys function.
If you’re using a non-Xorg machine the first option is probably what you’ll want to pick, but in the case of a Xorg machine option 3 is much simpler and better. I’m not actually sure the best way to do this on Wayland, but I guess I’ll have to figure that out eventually since Wayland is getting better and better.
You can set xkb settings either with the command line tool
could be placed in your
.Xinitrc for user settings or you can set them
system wide in your Xorg config. Most modern distros split the Xorg config into
various config files under
To disable the use of the caps lock key you can simply create a file in
90-disable-caps.conf (or similar). Then place
the below contents into that file. The files in that directory are loaded based
on their sort order, so traditionally the names begin with two numbers that
determine the load order.
Section "InputClass" Identifier "keyboard defaults" MatchIsKeyboard "on" Option "XKbOptions" "caps:none" EndSection
Basically this matches “keyboards” and sets the option
caps:none. A full list
of possible options is located inside
of the time you’ll want to swap caps for control or similar instead of outright
ctrl:nocaps Would switch it to control.
Added link showing some of wayland’s improvements.