We are currently migrating Bugzilla to GitHub issues.
Any changes made to the bug tracker now will be lost, so please do not post new bugs or make changes to them.
When we're done, all bug URLs will redirect to their equivalent location on the new bug tracker.

Bug 3417

Summary: Wrong SDL_Keycode for X11 Workman layout
Product: SDL Reporter: Braden Obrzut <admin>
Component: eventsAssignee: Sam Lantinga <slouken>
Status: ASSIGNED --- QA Contact: Sam Lantinga <slouken>
Severity: normal    
Priority: P2    
Version: HG 2.0   
Hardware: x86_64   
OS: Linux   

Description Braden Obrzut 2016-08-28 06:37:52 UTC
Tested with Hg changeset 9a277db2806d on Kubuntu 16.04 x86_64 (also affects version of SDL2 shipped with the distro).

I have my keyboard layout set to US-Workman in KDE and SDL handles this mostly fine except for the number keys.  Those get translated as follows:

1 = Return
2 = Escape
3 = Backspace
4 = Tab
5 = Space
6 = -
7 = =
8 = [
9 = ]

The beginning sequence there looks a lot like the scancodes in the switch statement on line 335 of SDL_x11keyboard.c, so I commented that switch block out.  With the modified SDL library the keyboard input works as expected with the keycode matching my layout and scancode matching qwerty.