Bug 434988 - keyboard shortcuts use shifted symbols (e.g., Meta+!) instead of the unshifted ones (e.g., Meta+Shift+1)
Summary: keyboard shortcuts use shifted symbols (e.g., Meta+!) instead of the unshifte...
Status: CONFIRMED
Alias: None
Product: systemsettings
Classification: Applications
Component: kcm_keys (show other bugs)
Version: 5.21.3
Platform: Arch Linux Linux
: NOR normal
Target Milestone: ---
Assignee: Plasma Bugs List
URL:
Keywords:
: 440163 489603 489920 (view as bug list)
Depends on: 415289
Blocks:
  Show dependency treegraph
 
Reported: 2021-03-26 18:13 UTC by 80p3fy75dc
Modified: 2024-10-15 14:17 UTC (History)
14 users (show)

See Also:
Latest Commit:
Version Fixed In:
Sentry Crash Report:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description 80p3fy75dc 2021-03-26 18:13:36 UTC
STEPS TO REPRODUCE

Tested with English US and French keymaps 
1. Go to System Settings > Shortcuts
2. Try to assign say "Meta+Shift+1" for "Window to Desktop 1" action


OBSERVED RESULT
As you press the keys to define the shortcut, "Meta" and "Shift" appear in the box with the wheel, but as soon as you press "1", the shortcut ends up being "Meta+!". It seems that "Shift" key cannot be used in combination with another key which has two variants. Indeed, "Meta+Shift+<any_letter>" or "Meta+Shift+* (the * key being on the numpad and not having any variant) work just fine. But "Meta+Shift+7" will lead to "Meta+&" and so on.

"Shift+<key>" alone without Meta gives mixed results as well: "Shift+F10" or "Shift+Down" are accepted but other combinations such as "Shift+!", "Shift+" or "Shift+4" aren't.

EXPECTED RESULT

I should be able to assign "Shift+<any_key> or "Meta+Shift+<any_key>" to an action.


SOFTWARE/OS VERSIONS
Windows: 
macOS: 
Linux/KDE Plasma: 
(available in About System)
KDE Plasma Version: 
KDE Frameworks Version: 
Qt Version: 


SOFTWARE/OS VERSIONS
Linux/KDE Plasma: Arch Linux/Gentoo
KDE Plasma Version: 5.21.3
KDE Frameworks Version: 5.80.0
Qt Version: 5.15.2
Comment 1 Andrey 2021-03-26 19:48:42 UTC
Could you check if it differs on Wayland?
Comment 2 80p3fy75dc 2021-03-26 21:09:47 UTC
(In reply to Andrey from comment #1)
> Could you check if it differs on Wayland?

I've just tried on Wayland and it doesn't make any difference unfortunately. Same behavior than on X11.
Comment 3 80p3fy75dc 2021-10-04 09:33:38 UTC
Any update?
Comment 4 Andrey 2021-10-04 11:39:01 UTC
Could you try to do some investigation and find related issues here or for Qt?
I think I saw something related with Shift modifier for shortcuts..

It would help to push it forward.
Comment 5 Jacopo 2023-06-04 17:51:43 UTC
Sorry to dig up this old bug, but it seems it's still unsolved.

This is my system info:

```
OS: Fedora Linux 37 KDE
KDE Plasma Version: 5.27.4
KDE Frameworks Version: 5.105.0
Qt Version: 5.15.9
Graphics Platform: Wayland
```

I'm pretty sure I wasn't seeing this on Kubuntu 20.04 LTS (which I believe shipped with X11).

The issue is exactly what described earlier: I can also confirm that "Ctrl+Shift+NumPad*" combinations are affected, even if I set the advanced keyboard setting "Numeric keypad always enters digits (as in macOS)".
Comment 6 Andrey 2023-06-06 18:05:45 UTC
What if you keep only English layout configured in your system?
Comment 7 Andrey 2024-01-12 19:03:58 UTC
(In reply to Andrey from comment #6)
> What if you keep only English layout configured in your system?
Comment 8 Bug Janitor Service 2024-01-27 03:45:41 UTC
Dear Bug Submitter,

This bug has been in NEEDSINFO status with no change for at least
15 days. Please provide the requested information as soon as
possible and set the bug status as REPORTED. Due to regular bug
tracker maintenance, if the bug is still in NEEDSINFO status with
no change in 30 days the bug will be closed as RESOLVED > WORKSFORME
due to lack of needed information.

For more information about our bug triaging procedures please read the
wiki located here:
https://community.kde.org/Guidelines_and_HOWTOs/Bug_triaging

If you have already provided the requested information, please
mark the bug as REPORTED so that the KDE team knows that the bug is
ready to be confirmed.

Thank you for helping us make KDE software even better for everyone!
Comment 9 Bug Janitor Service 2024-02-11 03:45:37 UTC
This bug has been in NEEDSINFO status with no change for at least
30 days. The bug is now closed as RESOLVED > WORKSFORME
due to lack of needed information.

For more information about our bug triaging procedures please read the
wiki located here:
https://community.kde.org/Guidelines_and_HOWTOs/Bug_triaging

Thank you for helping us make KDE software even better for everyone!
Comment 10 Andrew Shark 2024-02-11 09:03:47 UTC
This bug is valid.
Comment 11 Andrey 2024-02-11 18:49:35 UTC
(In reply to Andrey from comment #6)
> What if you keep only English layout configured in your system?
Comment 12 Bug Janitor Service 2024-02-26 03:46:13 UTC
Dear Bug Submitter,

This bug has been in NEEDSINFO status with no change for at least
15 days. Please provide the requested information as soon as
possible and set the bug status as REPORTED. Due to regular bug
tracker maintenance, if the bug is still in NEEDSINFO status with
no change in 30 days the bug will be closed as RESOLVED > WORKSFORME
due to lack of needed information.

For more information about our bug triaging procedures please read the
wiki located here:
https://community.kde.org/Guidelines_and_HOWTOs/Bug_triaging

If you have already provided the requested information, please
mark the bug as REPORTED so that the KDE team knows that the bug is
ready to be confirmed.

Thank you for helping us make KDE software even better for everyone!
Comment 13 Andrew Shark 2024-02-26 11:12:57 UTC
The bug is valid.
The layout does not matter.
Comment 14 80p3fy75dc 2024-03-12 09:49:44 UTC
Still occurs after updating to Plasma 6.

- Operating System: Arch Linux
- KDE Plasma Version: 6.0.1
- KDE Frameworks Version: 6.0.0
- Qt Version: 6.6.2
- Graphics Platform: Wayland

Same on X11.
Comment 15 Andrey 2024-03-14 11:36:09 UTC
(In reply to 80p3fy75dc from comment #0)
> 2. Try to assign say "Meta+Shift+1" for "Window to Desktop 1" action
> 
> OBSERVED RESULT
> As you press the keys to define the shortcut, "Meta" and "Shift" appear in
> the box with the wheel, but as soon as you press "1", the shortcut ends up
> being "Meta+!".
Sorry it's not quite clear to me if the actual problem is the resulted shortcut can't be triggered at all or you just prefer it would be "Meta+Shift+1" instead of "Meta+!"?
Comment 16 80p3fy75dc 2024-03-14 16:17:27 UTC
(In reply to Andrey from comment #15)
> (In reply to 80p3fy75dc from comment #0)
> > 2. Try to assign say "Meta+Shift+1" for "Window to Desktop 1" action
> > 
> > OBSERVED RESULT
> > As you press the keys to define the shortcut, "Meta" and "Shift" appear in
> > the box with the wheel, but as soon as you press "1", the shortcut ends up
> > being "Meta+!".
> Sorry it's not quite clear to me if the actual problem is the resulted
> shortcut can't be triggered at all or you just prefer it would be
> "Meta+Shift+1" instead of "Meta+!"?

The latter. I'd like to use "Meta+Shift+1" for "Window to Desktop 1" action.
Comment 17 Andrey 2024-03-18 17:20:08 UTC
Then the description is somewhat misleading as the Shift key is actually can be used in the shortcuts, it's just sometimes "consumed" by a keymap on XKB level.

I don't know an easy way to prevent this, if somebody looks how it's done in Gnome, it would be helpful.
Comment 18 fanzhuyifan 2024-08-01 19:53:26 UTC
Is this just a cosmetic issue where you would like the shortcut to appear as Meta+Shift+1? Because even though the shortcut appears as Meta+!, pressing Meta+Shift+1 still triggers it.

A related question is how we want shortcuts of this kind to be triggered in different layouts. Suppose in a different layout, shift+1 is not !, but shift+2 is !, do we want the shortcut to trigger when the user presses Meta+Shift+1, or when the user presses Meta+Shift+2?
Comment 19 fanzhuyifan 2024-08-03 01:07:56 UTC
The Qt documentation (https://doc.qt.io/qt-6/qkeysequence.html#keyboard-layout-issues) gives some rationale of why it is desirable to set shortcuts like Meta+! instead of Meta+Shift+1:

""" 
For example, the shortcuts, Ctrl plus and Ctrl minus, are often used as shortcuts for zoom operations in graphics applications, and these may be specified as "Ctrl++" and "Ctrl+-" respectively. However, the way these shortcuts are specified and interpreted depends on the keyboard layout. Users of Norwegian keyboards will note that the + and - keys are not adjacent on the keyboard, but will still be able to activate both shortcuts without needing to press the Shift key. However, users with British keyboards will need to hold down the Shift key to enter the + symbol, making the shortcut effectively the same as "Ctrl+Shift+=".

Although some developers might resort to fully specifying all the modifiers they use on their keyboards to activate a shortcut, this will also result in unexpected behavior for users of different keyboard layouts.

For example, a developer using a British keyboard may decide to specify "Ctrl+Shift+=" as the key sequence in order to create a shortcut that coincidentally behaves in the same way as Ctrl plus. However, the = key needs to be accessed using the Shift key on Norwegian keyboard, making the required shortcut effectively Ctrl Shift Shift = (an impossible key combination).
"""

Based on that, I think that this report should be closed as WONTFIX, unless there is a reasonable way to handle the problem raised above.
Comment 20 fanzhuyifan 2024-08-03 01:16:19 UTC
*** Bug 489920 has been marked as a duplicate of this bug. ***
Comment 21 fanzhuyifan 2024-08-03 01:17:53 UTC
*** Bug 440163 has been marked as a duplicate of this bug. ***
Comment 22 Zamundaaa 2024-08-15 13:26:19 UTC
*** Bug 491644 has been marked as a duplicate of this bug. ***
Comment 23 Nate Graham 2024-09-02 16:40:07 UTC
*** Bug 489603 has been marked as a duplicate of this bug. ***
Comment 24 Nate Graham 2024-09-30 19:16:04 UTC
*** Bug 493787 has been marked as a duplicate of this bug. ***
Comment 25 Nate Graham 2024-10-11 17:01:53 UTC
*** Bug 494543 has been marked as a duplicate of this bug. ***
Comment 26 Nate Graham 2024-10-14 16:14:50 UTC
*** Bug 493787 has been marked as a duplicate of this bug. ***