How can I stop the Alt key from triggering the menu bar of applications in Ubuntu 19.10?
I know that there are these post 1, post 2, and post 3, as well as https://docs.substance3d.com/spdoc/impossible-to-use-the-alt-keyboard-shortcut-on-linux-143720782.html but those solutions are no longer applicable. I did try searching for a similar option to the one in the answer of those questions but with no success.
You can do so by modifying the XKB configuration file like so:
/usr/share/X11/xkb/symbols/pc
file by running the following command in the terminal:include "altwin(meta_alt)"
like so://
before it like so:Save the file and exit the editor by pressing Ctrl + X then press Y.
Clear the XKB cache by running the following command in the terminal:
Notice:
If you choose to avoid the reboot and reload the new XKB configuration withe this command, layout switching will only be possible through the terminal and layout switching using hotkeys or the GUI will stop responding until you reboot the system.
This solution should disable the ALT functionality, but the physical key Alt itself will remain functional. So the key code can be detected by a utility like
xev
and then remapped for example to "Super Right" like so (replacing64
with the detected key number):It will then be available for use as a hot key or shortcut key exactly like ALT minus the undesired behavior.
Please refer to this answer for help
I had this issue on Ubuntu 18.04 and it was very annoying! I solved it by editing the following files:
and adding the following lines to it:
After this logout and then login.