While remapping keys I accidentally did something to change the behavior of my alt keys. If I have a window open and I press alt the window is grabbed and stuck to the cursor/arrow keys. This makes my frequent use of alt-tab useless.
The major change I made was with xmodmap, although I don't think this is the cause as they changes are reverted every time I reboot (I added a line to my .bashrc
to set my new mappings but this does not take effect until I open a terminal). I also have a backup of my original mapping which I used to reset my changes but that did not fix the issue.
Another change I made in an attempt to persist my xmodmap changes was to add a file in /etc/X11/Xsession.d/
as explained here. However, this did not work so I removed the file. I also tried creating a .xinitrc as explained in the top answer on that post but also subsequently deleted that.
None of the above changes explain my problem so I suspect that I deleted or edited something along the way and forgot about it.
Extra Details:
Running xmodmap -pke
shows nothing funny for keycode 64 (left alt):
keycode 64 = Alt_L Meta_L Alt_L Meta_L Alt_L Meta_L
The only shortcut mapped to either Alt key is Alt L to Key to show the HUD.
Changing this to another key combo (temporarily to alt q) did not fix the issue.
Plugging in an external keyboard verifies that it is not a hardware issue (the behavior is the same with the external keyboard).
What I have tried:
- Resetting my keyboard layout with
setxkbmap -layout us -option
- Resetting shortcuts with
gsettings reset-recursively org.gnome.desktop.wm.keybindings
I apologize for my rather vague details; I'd be happy to provide any more detail if needed.
gsettings reset org.gnome.desktop.input-sources xkb-options
– Gunnar Hjalmarsson Jul 08 '19 at 10:38alt
undersettings > keyboard > shortcuts > windows
. I think it wasmove window
in particular, which had the shortcutalt f7
. I have no idea how this got set in the first place but removing the entry by clicking on it and pressing backspace fixed it. This does not explain whyalt
on its own was doing the action foralt f7
but I suspect that is due to my water damaged keyboard. – Chauncey Nov 19 '19 at 20:04