Cannot use Windows key (Super_L) as part of a keyboard shortcut

Bug #8146 reported by Mary Gardiner
28
Affects Status Importance Assigned to Milestone
control-center (Ubuntu)
Fix Released
Medium
Unassigned

Bug Description

I like to use Windows+1, Windows+2 etc as my "Switch to workspace 1", "Switch to
workspace 2"... keybindings.

If I try to set this in Computer -> Desktop preferences -> Keyboard shortcuts,
it only lets me enter the Windows key itself (it calls it "Super_L") as a
shortcut, but it does not let me combine it with other keys.

Revision history for this message
Matt Zimmerman (mdz) wrote :

I think this is a general xfree86/XKB problem; Daniel?

Revision history for this message
Daniel Stone (daniels) wrote :

I believe so, yeah, and I think Branden might have just committed a patch to
make this sort of thing Just Work again. But I don't really understand XKB well
enough to make the call, sorry. Fabio, any idea what's going on?

Revision history for this message
Fabio Massimo Di Nitto (fabbione) wrote :

Yes, i think that Branden committed the fix for this right yesterday. I will
take the bug.

Revision history for this message
Fabio Massimo Di Nitto (fabbione) wrote :

Fixed in X ubuntu19 upload.

Revision history for this message
Mary Gardiner (puzzlement) wrote :

This is not fixed for me: as far as I can tell I am using the very latest Warty
packages. (The x packages seem to mainly be ubuntu21 versions.)

Reproduction:

1. Go to Computer menu

2. Go to Desktop Preferences

3. Go to Keyboard Shortcuts

4. Go down to "Switch to Workspace 1", which in my case is already set to
"<Ctrl><Alt>1".

5. Select the "Shortcut" column, which then reads "New accelerator..."

6. Press Windows key and 1 key at the same time

7. Shortcut reads "Super_L", rather than including 1 in the shortcut.

Here's the xev info for my Windows key:

KeyRelease event, serial 26, synthetic NO, window 0x2e00001,
    root 0x3f, subw 0x2e00002, time 14632771, (34,56), root:(40,127),
    state 0x40, keycode 115 (keysym 0xffeb, Super_L), same_screen YES,
    XLookupString gives 0 bytes: ""

Revision history for this message
Andrew Bennetts (spiv) wrote :

I'm also seeing the exact same problem as Mary, even with the ubuntu21 packages.

Revision history for this message
Fabio Massimo Di Nitto (fabbione) wrote :

Ok.. this is a stupid question.. did you restart X after the upgrade?

I am getting this output from xev:

FocusIn event, serial 26, synthetic NO, window 0x2600001,
    mode NotifyUngrab, detail NotifyAncestor

KeymapNotify event, serial 26, synthetic NO, window 0x0,
    keys: 2 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
           0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0

but i cannot use Super_L + 1 in the keyboard modifiers.

Revision history for this message
Mary Gardiner (puzzlement) wrote :

I've restarted it several times since th upgrade to 19, and specifically, I
restarted it (by logging out and logging back in) and then retested just before
I reopened the bug.

Revision history for this message
Fabio Massimo Di Nitto (fabbione) wrote :

Sorry but logout and login isn't enough. You need to switch to console and
restart GDM. the X server keeps running otherwise.

Revision history for this message
Andrew Bennetts (spiv) wrote :

I did that, and I still see this bug.

Revision history for this message
Mary Gardiner (puzzlement) wrote :

I completely rebooted the machine only last night and warty was up-to-date at
that time. This morning the Windows key could not be used in shortcuts.

Next time I log out and log back in I'll report again, but I can't do that for
at least another 24 hours because I'll lose a running process I need to keep.

Revision history for this message
Fabio Massimo Di Nitto (fabbione) wrote :

Mary thanks a lot for your cooperation.

Revision history for this message
Nathan Howell (neh) wrote :

I have the same problem, and I've rebooted since upgrading the X packages as well.

Revision history for this message
Sebastien Bacher (seb128) wrote :

Just curious, have you used the patch attached in http://bugs.debian.org/259740
for ubuntu19 ?

Revision history for this message
Fabio Massimo Di Nitto (fabbione) wrote :

The patch is an update of the FAQ, but yes. it's included.

Revision history for this message
Denis Barbier (barbier) wrote :

Setting altwin:super_win option should do the trick. The problem is that GNOME components are XKB-unaware, so modifiers have to be bound to real keys. Adding this option by default in a GNOME environment is surely a good idea.

Revision history for this message
Fabio Massimo Di Nitto (fabbione) wrote :

Thanks for the explanation Denis! So at the end this is not a Xfree86 bug.
I will keep it open since I am pretty sure tons of people will search for similar
information later on.

Fabio

Revision history for this message
Mary Gardiner (puzzlement) wrote :

For people playing along at home, it seems one way to do this is Computer Menu
-> Desktop Preferences -> Keyboard -> Layout Options tab. Select "Alt/Win key
behaviour" and then select "Super is mapped to Win-keys (default)" and press the
"Add+" button, and then "Close".

After that, I could use the Windows key in shortcuts. I have no idea if this
will persist after relogin, and obviously it wouldn't set it for the machine's
other users.

Immense amounts of relevant discussion is available at http://bugs.debian.org/271259

Revision history for this message
Fabio Massimo Di Nitto (fabbione) wrote :

Sebastian, do you think we add a check to gnome on startup that if X is >
4.3.0.dfsg.1-4 we enable this option by default?

Revision history for this message
Nathan Howell (neh) wrote :

Setting that option doesn't entirely work for me. It lets me assign Super_L
correctly in combination with other keys, but it doesn't work for all
combinations. <Mod4><s> works for shading a window, but <Mod4><f> for opening my
homedir doesn't. <Shift><Mod4><1> works to move a window to workspace 1, but
<Mod4><1> to switch to workspace 1 does not. It goes on like that. Anybody else?

Revision history for this message
Mary Gardiner (puzzlement) wrote :

I haven't used it in many keyboard combinations yet, but:

<Mod>1 through to <Mod>4 are all working for "Switch to window..."

Revision history for this message
Nathan Howell (neh) wrote :

Ok, it all seems to work now. I had forgotten to restart X. Oops.

Revision history for this message
Ross Burton (ross) wrote :

Adding "Super is mapped to Win-keys (default)" didn't fix this for me with
ubuntu24, in the Keyboard Shortcuts Super is treated as a normal key and not a
modifier.

Revision history for this message
Sebastien Bacher (seb128) wrote :

*** Bug 9785 has been marked as a duplicate of this bug. ***

Revision history for this message
Daniel Stone (daniels) wrote :

Does it work now for you guys, with or without X.Org? We've got a few updates
in there.

Revision history for this message
Daniel Stone (daniels) wrote :

Closing old NEEDINFO.

Revision history for this message
Ole Laursen (olau) wrote :

It doesn't work for me out of the box, but if I select the "Super is mapped to
Win-keys (default)", then it works. But since this is said to be the default,
shouldn't it just work?

Without the "Super is mapped to Win-keys (default)", I get Super_L in the
keybindings preferences. With it, I get <Mod4> and can combine it with other keys.

Revision history for this message
Wladston Viana (wladston) wrote :

I confirm this bug, it's a happening with an out-of-the-box Dapper Drake.

The Windows key can be used in combinations after marking ""Super is mapped to Win-keys (default)".

Revision history for this message
Nick Andrik (andrikos) wrote :

Another way to do this is to press the Win Key before clicking to change the shortcut, hit the letter and finally release the Win Key.

Revision history for this message
Ivan Ivanoff (spammeroff) wrote :

And at this time (Gutsy Gibbon Tribe 5) I cannot assign Win key as modifier for all shortcuts. Only one shortcut - "Win+M" could be made.

Revision history for this message
Martin Olsson (mnemo) wrote :

I'm still experiencing this problem with a final Gutsy that has all the updates as of today.

I tried to bind SUPER_KEY+D to "Show Desktop" but when I try to configure that it just assumes I want only SUPER_KEY and it ignores my D keystroke. It's like ALT, CTRL etc are modifier keys that can be used in combinations with other keys but for some reason the SUPER key isn't configured to be combined with other keys.

Revision history for this message
Cody A.W. Somerville (cody-somerville) wrote :

This bug seems present (again?) in Gutsy and Hardy. Reopening bug.

Changed in control-center:
status: Fix Released → Confirmed
Revision history for this message
Sebastien Bacher (seb128) wrote :

there is other bugs open about the issue no need to reopen this closed one

Changed in control-center:
assignee: daniels → nobody
status: Confirmed → Fix Released
Revision history for this message
aidave (aidave) wrote :

I also have this bug on Gutsy

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Duplicates of this bug

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.