Bug 484439 - Regression with Alt+Shift layout switching
Summary: Regression with Alt+Shift layout switching
Status: RESOLVED UPSTREAM
Alias: None
Product: kwin
Classification: Plasma
Component: input (show other bugs)
Version: 6.0.2
Platform: Ubuntu Linux
: NOR major
Target Milestone: ---
Assignee: KWin default assignee
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2024-03-25 09:10 UTC by Kirill Zhumarin
Modified: 2024-04-12 10:20 UTC (History)
2 users (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Kirill Zhumarin 2024-03-25 09:10:01 UTC
SUMMARY
It is impossible to normally use `Alt+Shift`.

STEPS TO REPRODUCE
1. Add 2+ input layouts.
2. Enable `Input devices` -\> `Keyboard` -\> `Advanced` -\> `Switching to another layout` -\> `[x] Alt+Shift`

OBSERVED RESULT
1. Press `Alt`
2. Press `Shift`
3. Release ONLY `Alt`
4. Try to type text. Typed text is lowercase, `Shift` is ignored.

EXPECTED RESULT
1. Press `Alt`
2. Press `Shift`
3. Release ONLY `Alt`
4. Try to type text. Typed text is uppercase.

SOFTWARE/OS VERSIONS
Bug is present in both Plasma 5 and Plasma 6.

ADDITIONAL INFORMATION
Comment 1 Kirill Zhumarin 2024-03-25 09:11:27 UTC
Workaround: https://github.com/Azq2/alt-shift-kbd-layout-switcher
Comment 2 Kirill Zhumarin 2024-03-25 09:14:22 UTC
P.S. In Unity, GNOME, Windows works fine.
Comment 3 fanzhuyifan 2024-03-27 16:24:10 UTC
Can reproduce on wayland, git build. This only happens when Alt is pressed before Shift.
Comment 4 fanzhuyifan 2024-03-27 16:49:22 UTC
I can also reproduce this on x11. So I think this is an upstream xkb issue.
Comment 5 fanzhuyifan 2024-03-27 17:38:48 UTC
(In reply to fanzhuyifan from comment #4)
> I can also reproduce this on x11. So I think this is an upstream xkb issue.

I confirmed that I can also reproduce this on XFCE, with a command like `setxkbmap -layout rs,rs,us,de -variant latin,,dvp, -option 'grp:alt_shift_toggle'`

So please report this issue to xkb.
Comment 6 Wismill 2024-04-12 10:20:23 UTC
This is another occurrence of the infamous “need to kick hotkeys on release, not press” (see: https://gitlab.freedesktop.org/xorg/xserver/-/issues/258). This is not a bug per se, but a known limitation of the XKB protocol.