English

# What could cause the alt key to stop working in two terminal apps?

I use lots of keyboard shortcuts when I'm working with bash in a terminal. Two that I use heavily are Alt-d and Alt-. to delete the following word and to bring in the last argument of the previous command, respectively. In the last twenty-four hours--somewhere in the middle of a marathon coding session--I noticed that they stopped working in both of the terminal applications that I use heavily (Terminator and Guake); however, Alt key presses are still registered by the apps themselves (e.g., in Terminator, Alt-Left switches to the window frame on the left, and that works). Edit: In other news Esc-d or Esc-. work. So I'm gonna look into the whole meta thing...

Also, my mind was just blown when I realized that Alt still works in gnome-terminal (which I never use). Before that I thought this was a bash issue. Alt-key combos also work just fine every where else in my Gnome desktop & applications. WTH!

Any pointers?

edit retag close delete

Sort by » oldest newest most voted

@Izap had the same problem and tracked it down in another question of his.

Basically, a GTK2 change broke meta keys for vte-based terminals. Izap came up with a work-around, and I posted what I consider an even better work-around here.

Short version:

yum --enablerepo=updates-testing update vte


That fixes terminator and guake on my system.

more

For gtk3-based apps (such as gnome-terminal) in Fedora 16: the pending update for vte3 in updates-testing fixes this: https://admin.fedoraproject.org/updates/FEDORA-2011-17004/vte3-0.30.1-3.fc16

to fix simply run (as root):

yum --enablerepo=updates-testing install vte3


Note that this doesn't fix the gtk2-based apps like terminator

more

We have the same problem. In our case, it was an upgrade to Fedora 16 that caused this. You didn't by any chance update to Fedora 16 at some point, did you? Seems extraordinarily unlikely, but i have to ask.

We see this under GNOME 3 and Xfce.

We have noticed that we can still use the escape key to get these behaviours - escape then dot does the same as alt-dot. That's standard; composing with escape is the traditional way of sending a meta on keyboards which lack a meta key. Chording with alt should normally do the same, but doesn't.

more

Wow. I had forgotten about Esc as the meta key for the same purpose! That's a bit helpful until I figure this out. Thanks for reminding me! Regarding F16: I was already on F16 when this all of a sudden happened (and I couldn't pin it to any particular update).

( 2011-12-07 14:49:37 +0000 )edit

@twic: In case you haven't noticed, me & Izap posted temporary work-arounds to this problem. In short: http://ask.fedoraproject.org/question/594/after-update-to-gtk2-2248-2-meta-and-alt-keys-no?answer=1170

( 2011-12-07 21:28:21 +0000 )edit

Yup, the workaround is to downgrade to previous gtk2 and hold on with upgrading a bit until they fix the issue.

wget http://kojipkgs.fedoraproject.org/packages/gtk2/2.24.7/3.fc16/x86_64/gtk2-2.24.7-3.fc16.x86_64.rpm
wget http://kojipkgs.fedoraproject.org/packages/gtk2/2.24.7/3.fc16/x86_64/gtk2-devel-2.24.7-3.fc16.x86_64.rpm
sudo rpm -Uvh --force gtk2*rpm

more

I don't understand why you would promote downgrading to an older version of gtk2 (with rpm, no less) instead of updating to a patched vte rpm...? Both are obviously temporary measures, so why advocate the more-complicated (and more likely to cause problems) choice?

( 2011-12-07 20:52:24 +0000 )edit

Which alt key doesn't work? The left one or the right one?

more

Neither alt keys work for bash-shortcuts in those two terminal apps.

( 2011-12-02 09:54:55 +0000 )edit

[hide preview]