Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

SDLK/KEY for y/z and "KEYB GR" and ALTGR-combos on a german Win10 #89

Open
guidol70 opened this issue Nov 18, 2024 · 2 comments
Open

SDLK/KEY for y/z and "KEYB GR" and ALTGR-combos on a german Win10 #89

guidol70 opened this issue Nov 18, 2024 · 2 comments
Labels

Comments

@guidol70
Copy link

guidol70 commented Nov 18, 2024

In the keymap.map normally is configured:
SDLK_y = KEY_Y
SDLK_z = KEY_Z

When I start the IBMulator (2121 US ROM with US DOS 4.01) I do get at the "Command prompt"
a Y for a Y and a Z for an Z - which is a little bit odd, because "KYB GR" isnt loaded.
When I load "KEYB GR" Y and Z are swapped. So all other key work fine on a german keyboard,
but Y and Z arent right this way (no normal behaviour on a DOS-PC) :(

To resolve this (normal behaviour on a DOS-PC) I changed the lines in the keymap.map to
SDLK_z = KEY_Y
SDLK_y = KEY_Z

So - before loading "KEYB GR" a Y is a Z and Z is a Y - like on a real PC.
After loading "KEYB GR" now these are swapped like they should and all other (working) keys
show what they should show with a german keyboard ;)

Now I only do MISS some ALTGR-combinations:
@ - ALTGR-Q
| - ALTGR-<>
~ - ALTGR-+
\ - ALTGR-ß (?? SDL_SCANCODE_BACKSLASH = KEY_BACKSLASH ??)
and maybe
€ - ALTGR-E

Is there any solution to this ALTGR-mapping problem?

Kind regards
Guido

@barotto
Copy link
Owner

barotto commented Nov 19, 2024

Hello Guido, thank you for reporting these problems which are specific to the german keybord layout. I have no knowledge on QWERTZ keyboards but your solution of swapping the Y and Z mappings seems correct. Maybe you can also try with the SDL_SCANCODE_* identifiers, like SDL_SCANCODE_Z = KEY_Z. Scancodes should map to physical keys.

As for the ALTGR combinations problem let me see if I can replicate the situation and maybe find a solution.

@Mutamid
Copy link

Mutamid commented Dec 2, 2024

The problems with the AltGR key also occurred with the Spanish keyboard in Ibmulator, Dosbox, Dosbox-x, in different versions of Windows. In Dosbox-x it is already fixed, I don't know if in Dosbox too, because I don't use it anymore. I haven't been able to check if it has been fixed in Ibmulator, because I'm using a PC with 32-bit Windows. The solution I found was to select an English keyboard in Windows when using these emulators. And then within these emulators select the Spanish keyboard. And then all the keys worked correctly, including AltGr. In fact, out of habit I select the English keyboard in Windows just before opening Ibmulator. When I exit it I select the Spanish keyboard again in Windows. You can try this solution, selecting an English keyboard on a German Windows and then inside Ibmulator having a German keyboard selected.

Regards

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants