GNOME Bugzilla – Bug 101960
keyboard layout switcher hot key doesn't work reliably
Last modified: 2004-12-22 21:47:04 UTC
See https://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=80249 Problem is present in gnome-applets-2.0.1-6, in Red Hat Linux Beta Phoebe, released on Dec 23. HP asked me to file it upstream. Description of problem: If you choose Mod1-Shift_L (the default) as the keyboard layout switch hotkey, it only switches the keyboard layout if you hold alt, press left shift, release shift and then release alt. If you release alt before shift, it seems to revert to the original state. Is this intentional, just to avoid accidental switching? Version-Release number of selected component (if applicable): How reproducible: Always Steps to Reproduce: 1.Press Alt and hold 2.Press shift 3.Release Alt Actual Results: Keyboard layout is unchanged. Expected Results: I'd expect it to change. Additional info: I can see that this may well be a feature, but it can be annoying if you release both keys almost at the same time. It could try to time the events to avoid unintended changes, e.g., if the time between the pressing of the second key and the releasing either key is larger than the interval between the pressing of both keys, then it's an intended layout switch. This helps avoid pressing the shift right before releasing the alt when a layout switch is not intended.
For the record, it's fixed in Red Hat Linux beta 8.0.93 (second phoebe). Dunno whether it was fixed upstream or with a local patch.
Could you figure out whether it was a local fix or upstream? Marking as NEEDINFO
Alexandre: do you have an anwser ?
It's still not working in 2.4.x at least.
I can get it to work using alt+space, but not using two modifiers together.
*** Bug 121763 has been marked as a duplicate of this bug. ***
*** Bug 123103 has been marked as a duplicate of this bug. ***
*** Bug 125335 has been marked as a duplicate of this bug. ***
If you say that the bugs 121763, 123103, 125335 are the duplicates of this bug then we should change its description. As I can see on my Mandrake 9.2 and from comments on these 3 bugs the sequence of pressing/releasing doesn't matter. For example, in my case, switching doesn't work in both cases - when I release first Shift or Alt . FYI: It doesn't work when I try to use Ctrl-Shift either. My keyboard layouts are "us" and "ru-rev".
Isn't the current summary adequate? I think I've had problems with using any two modifiers in combination. The only thing I tried that worked was alt+space
Created attachment 21116 [details] [review] a fix for gnome 2.4
The attached patch works for me, and fixes two things: - As originally reported in this bug entry, releasing order of keys did matter. Now it doesn't, as the layout is changed as soon as you press the hotkey, not when you release it. - Hotkeys full of modifiers (e.g. Alt-Shift_L) didn't work at all, most likely because at the time Shift_L was released, it checked whether all the modifiers (both Alt and Shift_L) were pressed and found that they aren't. Now it works, Alt-Shift_L switches the layout.
*** Bug 121766 has been marked as a duplicate of this bug. ***
adding PATCH keyword
Applied. Thanks a lot Egmont.