Re: [hatari-devel] Keypad / Numlock handling |
[ Thread Index |
Date Index
| More lists.tuxfamily.org/hatari-devel Archives
]
- To: hatari-devel@xxxxxxxxxxxxxxxxxxx
- Subject: Re: [hatari-devel] Keypad / Numlock handling
- From: Thomas Huth <th.huth@xxxxxxxxx>
- Date: Sat, 16 Oct 2021 07:14:28 +0000
- Dkim-signature: v=1; a=rsa-sha256; c=relaxed/simple; d=posteo.de; s=2017; t=1634368473; bh=Rh2g+DdXGzJoe72fHRbVnnyMKoLc+Wh/wAk3gG0Ymfg=; h=Date:From:To:Subject:From; b=fZ81VQgPh374lzODqVBctORBKGXR0umlcZv1oXApQbo2QBed1iIXPnvQ2m72BemLO yUznGxhDjC4oJ6O7Ii6WIJZ1u7ufcg2ZNd79CYyH214Cx5YB8Cp3IOKiG9rsTbGNsQ Yk1bZFJzQlGhcsMAB0LH5U/mLI2F0u3OEZAOZwraVBtektKLMJCPBRlBHY/Qz+1IMO ETTaBLuuZch2Nf6oovIibyAIiPJubluK555f9Li2+j6xZ3cr4ZrooFBOtH9wH/C+/c eRajmz111X7oqbEzKdziFRM6hXCGtFp7iPiBb4yntxsB2DogLiqI52taSucaBLGWJo oGGap8fqhw0KQ==
Am Thu, 14 Oct 2021 23:28:11 +0300
schrieb Eero Tamminen <oak@xxxxxxxxxxxxxx>:
> Hi,
>
> While going through:
> https://wiki.libsdl.org/SDL_Scancode
>
> And the Google image search results, I noticed
> that there are quite a few keypads that offer
> also other keys than numbers, e.g. letters.
>
> Although such keypads are a bit rare, maybe we
> should convert those keys to corresponding Atari
> keys too?
We could add a mapping - but to which destination keys would you map
them? For example, you could map SDLK_KP_A to scancode 0x1e, then you
would get an "A" with keyboard layouts that are similar to the
US-layout. But it will completely fail if the user is using a French
TOS version... Ok, same thing happens with the symbolic key mapping,
but honestly I'm still dreaming of getting rid of the symbolic key
mapping in Hatari completely, now that we do not have to support SDL1
anymore. I think it should be possible to always use the scancode
mapping now with SDL2 since it guarantees the layout of the scancodes
on all systems (with SDL1, for example, scancode layout on macOS was
completely different), but I haven't had any spare time to have a
closer look at that possibility of optimization yet.
Thomas