wslg: Alt_gr key stops working in german keylayout when using wslg
Environment
Windows build number: Microsoft Windows [Version 10.0.21364.1]
Your Distribution version: Ubuntu 21.04
Your WSLg version: 1.0.17.1
Steps to reproduce
- Use a german ISO keyboard with german keyboard layout.
- Press things like ALT_GR+ß
Expected: Returns
Reality: Returns ß
WSL logs:
- Attach WSLg logs from
/mnt/wslg
You can access the wslg logs using explorer at: \\wsl$\<Distro-Name>\mnt\wslg
(e.g.: \\wsl$\Ubuntu-20.04\mnt\wslg
)
- pulseaudio.log
- weston.log
versions.txt
(No permission apparently and 0 bytes)
Expected behavior
When using alt_gr it should be registered
Actual behavior
Modifier key alt_gr doesnt get recognized
Possible related cause
According to https://superuser.com/a/1245750 this is most likely due to how RDP in windows 10 behaves.
About this issue
- Original URL
- State: closed
- Created 3 years ago
- Comments: 21 (7 by maintainers)
Commits related to this issue
- Add `libsharedguestalloc` (#88) * Add `libsharedguestalloc` * Update Dockerfile — committed to microsoft/wslg by viniciusjarina 4 years ago
Given this was closed over a year ago, which “future release of Windows” are we waiting for to have this behavior fixed?
Hi. Windows RDP client software team found the issue in mstsc.exe, this will be fixed in future release of Windows. thanks!
@marbon87, WSLg automatically match Linux side keyboard layout with currently selected keyboard layout at Windows side, so basically no need to do setxkbmap, and according to https://learn.microsoft.com/en-us/globalization/keyboards/kbdgr, AtlGr + ‘y’ is not assigned to anything. If key is not assigned at Windows side, no input to be sent to WSLg, thus even xkb has some assignment for that combination, it won’t produce any input, thanks!
@adesso-os, currently WSLg doesn’t work properly with custom keyboard layout which is tracked by https://github.com/microsoft/wslg/issues/173. So I think, in your case, Linux side is default to English layout in Linux side, thus AltGr is not working, thanks!
@MTRNord i apologize, i hadn’t realize the relation to WSLg… if this happen only when WSLg is enable we’ll take the first look, no need to open a bug through the feedback up then.
Workaround is to run
wsl --shutdown
as that closes the RDP connection