1

As I am writing a lot of LaTeX, I'd like the CapsLock key to instead print a \ (AltGr+8 on my keyboard). I am running Ubuntu 23.10.

I installed gnome-tweaks, which allowed me to remap Caps Lock to something like Hyper, and then I ran xcape -e 'Hyper_L=backslash'. I then switched from Wayland to Xorg. However, two issues arose:

  1. this instead prints the underscore _ character, and
  2. it does it very slowly, there is about a one second delay before the character gets printed.

I eventually tried installing AutoKey, but it just remaps keyboard shortcuts to text (solely typing a special key alone won't do anything, it needs a letter as well). I tried remapping the Hyper+A to a backslash, but nothing was being printed.

How can I perform this modification?

Alternatively, I could instead remap the ² key to the \ character, but this seems like it will be even more difficult due to the special nature of that key?

Anthony
  • 111

0 Answers0