Ubuntu 12.04, Firefox 13.0, xfce

For some reason, my Firefox installation has stopped paying attention to ALT keystroke combinations. That is, when I try an ALT-something key combination, I get the "something" as if ALT wasn't pressed at all. The "ALT" mechanism works fine in all the other apps I've tried; it used to work in Firefox (like, literally for years and years, until just the other day).

I've tried running on a new Firefox profile, and it behaves the same way, so I don't think it's a corrupted profile. I've got another laptop, different hardware, but essentially the same setup as this one, and Firefox and the "ALT" key get along fine there.

I have no idea where to even start trying to diagnose this. The general issue of keystroke processing on Linux is, I know, a fantastically complicated area, but since my "ALT" key seems to work perfectly well in every other application on the computer, I'm thinking this has something to do with some weird Firefox configuration thing.

What might be the problem? What can I do to investigate what's going wrong?

edit — Uninstalled/reinstalled Firefox, no effect. Still can't find another application on the system that doesn't understand the ALT key.

  • If you guys think this should be in "Ask Ubuntu", that's fine by me. – Pointy Jun 15 '12 at 1:02
  • I know on Windows, keys get messed up when you work with virtual machines. (Not sure if that has to do anything with your problem, but thought I'd mention it just in case...) – Mehrdad Jun 15 '12 at 1:07
  • Thanks - I don't think that's what's happening to me here, but I bet you're right about it being a possibility. My host OS is Ubuntu on this machine, and it's the native Firefox. It worked fine up until a few days ago; I must have changed something unwittingly but I have no clue what it was. – Pointy Jun 15 '12 at 1:12

You may need to reinitialize your keyboard mapping

  • from an xterm run setxkbmap followed by xmodmap

Other things to check

  • Remove lvl3:ralt_switch if present in /etc/default/console-setup

analyze the output from this procedure:

  • from xterm: xev | grep -B 4 -C 4 KeyPress
  • move mouse into the terminal window
  • make a keypress using LEFT-ALT
  • next make a keypress using RIGHT-ALT
  • I'll do those things, but it should be noted that my ALT keys work perfectly well in every other application I run on this system. It's only Firefox that has the problem. – Pointy Jun 15 '12 at 3:43
  • OK now that was a bad idea. The setxkbmap program totally blew away all my keyhboard mappings (that I've been using literally since the early 1990's with no issues at all). – Pointy Jun 15 '12 at 3:44
  • well if it's something outside FF, how is it that FF is the only thing affected? Chrome, for example, obeys the ALT key. So does xterm. So does every other application I've tried, which is basically everything on the system with a GUI. – Pointy Jun 15 '12 at 3:46
  • The xev program shows that my ALT keys are working perfectly well. – Pointy Jun 15 '12 at 3:47
  • Yes, the ALT key works in every single thing on the system except Firefox. This is undoubtedly a Firefox issue. – Pointy Jun 15 '12 at 3:47

I have exactly same problem (my case is archlinux) and I found a fix that works for me: Add/change a line:

Option "XkbVariant" "intl"

to your /etc/X11/xorg.conf.d/10-evdev.conf

Section "InputClass"
    Identifier "evdev keyboard catchall"
    MatchIsKeyboard "on"
    MatchDevicePath "/dev/input/event*"
    Driver "evdev"
    Option "XkbModel" "asus_laptop"
    Option "XkbVariant" "intl"
    Option "XkbLayout" "us"

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.