Bug 479807

Summary: Conflict between Task Switcher's reverse navigation and Alt+Shift keyboard layout switching shortcut in KDE Plasma.
Product: [Plasma] kwin Reporter: Ilia Karpov <ilia.karpov.96>
Component: inputAssignee: KWin default assignee <kwin-bugs-null>
Status: RESOLVED DUPLICATE    
Severity: minor CC: fanzhuyifan, ilia.karpov.96
Priority: NOR Keywords: accessibility, investigated, multiscreen, regression, triaged, usability
Version First Reported In: git-stable-Plasma/5.27   
Target Milestone: ---   
Platform: Arch Linux   
OS: Linux   
See Also: https://bugs.kde.org/show_bug.cgi?id=438991
Latest Commit: Version Fixed/Implemented In:
Sentry Crash Report:

Description Ilia Karpov 2024-01-14 15:49:21 UTC
**SUMMARY**

Conflict between Task Switcher's reverse navigation and Alt+Shift keyboard layout switching shortcut in KDE Plasma.

**STEPS TO REPRODUCE**
1. Go to `System Settings > Keyboard > Layouts` and set the main shortcut for switching to another layout to `[x] Alt + Shift`.
2. Initiate the Task Switcher by pressing Alt+Tab and continue holding down Alt to keep the Task Switcher active.
3. While holding down Alt, attempt to reverse navigate through tasks using Shift+Tab.

**OBSERVED RESULT**

The Task Switcher does not respond to the Shift+Tab input for reverse navigation when Alt+Shift is configured as the shortcut for keyboard layout switching.

**EXPECTED RESULT**

The Task Switcher should allow reverse task navigation using Shift+Tab while Alt is held down, even when Alt+Shift is used as a keyboard layout switching shortcut.

**SOFTWARE/OS VERSIONS**
Linux/KDE Plasma: Arch Linux
KDE Plasma Version: 5.27.9
KDE Frameworks Version: 5.111.0
Qt Version: 5.15.11

**ADDITIONAL INFORMATION**

This issue seems to indicate a potential conflict in keyboard shortcuts handling, specifically when Alt+Shift is used for both task switching and keyboard layout changes in KDE Plasma.
Comment 1 fanzhuyifan 2024-01-14 17:03:17 UTC
Seems like 438991, which has been fixed in 6.0.

Could you check the relevant entry in .config/kglobalshortcutsrc to see if it says Alt+Shift+Tab? If changing it to Alt+Shift+Backtab works then it is a dupe of 438991.

Thanks!
Comment 2 Ilia Karpov 2024-01-14 22:49:23 UTC
Thank you for the prompt reply!

Regrettably, the configuration in `~/.config/kglobalshortcutsrc` is already correctly set to `Walk Through Windows (Reverse)=Alt+Shift+Backtab,Alt+Shift+Backtab,Walk Through Windows (Reverse)`. Despite this, the issue I've described continues to persist.

To further investigate, I conducted a test on a clean installation of Manjaro and observed the same behavior. This suggests that the problem might not be isolated to my primary setup but could be a broader issue.
Comment 3 fanzhuyifan 2024-01-14 22:54:39 UTC
I tried reproducing this but on plasma 6 master (wayland) I cannot even assign alt+shift as a shortcut : (
Comment 4 Ilia Karpov 2024-01-15 07:43:32 UTC
Thank you for your attempt to reproduce the issue. It's important to note that the configuration for keyboard layout switching can indeed cause some confusion. When setting shortcuts under `Workspace/Shortcuts/Shortcuts/Switch to Next Keyboard Layout`, it is true that `Alt+Tab` might not register as expected.

However, my reference was specifically to the configuration found under `Hardware/Input Devices/Keyboard/Tab: Advanced/Switching to another layout`. In this section, it is indeed possible to explicitly set `Alt+Tab` as a shortcut for switching keyboard layouts. This distinction could be a crucial factor in understanding the behavior you've observed in Plasma 6 master (Wayland).
Comment 5 Vlad Zahorodnii 2024-01-17 15:54:34 UTC
I believe that the keyboard layout switching shortcut should trigger only when releasing, which should this bug.

*** This bug has been marked as a duplicate of bug 464805 ***
Comment 6 Ilia Karpov 2024-01-17 16:47:37 UTC
Thank you for your response.
Should I or another individual wish to contribute towards addressing this issue, could you advise on the most suitable starting point within the KDE components?
Comment 7 fanzhuyifan 2024-01-17 17:09:53 UTC
(In reply to Ilia Karpov from comment #6)
> Thank you for your response.
> Should I or another individual wish to contribute towards addressing this
> issue, could you advise on the most suitable starting point within the KDE
> components?

Thank you for your interest! A good starting place is this: https://community.kde.org/Get_Involved
We always need more contributors, not just in development.
You are also welcome to hang out in the matrix channels: https://community.kde.org/Matrix