Re: [hatari-devel] Enhanced keymap support

[ Thread Index | Date Index | More lists.tuxfamily.org/hatari-devel Archives ]


Hi Vincent,

Would you have time to test this?

It should fix your issues with the previous versions.

(All numbers are now decimal, for compatibility with earlier Hatari keymap files.)


	- Eero

On 11.11.2021 1.50, Eero Tamminen wrote:
Attached is new version of the patch series, with
following changes:

* Fix: KeysDown[] cleared on reset
* Fix: KeysDown[scancode] cleared on mapping
* Same SDL scancode can have multiple mappings
* Special handling for SHIFT, so that one does
   not need two mappings unless one really wants
   separate mappings for left & right SHIFT
* "KMOD_" prefixes dropped from SDL modifier names
* dec -> hex conversion patch dropped

Attached is also keymap file containing examples
of the mappings with documentation.


SDL scancode names used in mapping file need to
match case of their SDL names.  To help with that,
I've added "listkeys" program back to Hatari.

Modifier names need to be specified as upper case.
That way they're easier to differentiate from SDL
scancode names which are CamelCase.


Vincent, could you give it a try?

Thomas, would you have time to check the commits?


     - Eero

PS. in the mapping file, I'm using "CTRL" for SDL
modifier name, but "CONTROL" for Atari modifier
name:

* SDL mod name comes from SDL KMOD_CTRL define
   and SDL's own name for the key:
   - https://wiki.libsdl.org/SDL_Scancode

* Atari mod name comes from the name of the key
   on the actual Atari keyboard:
   - http://tho-otto.de/keyboards/
   - https://en.wikipedia.org/wiki/Atari_ST#/media/File:Atari_1040STf.jpg




Mail converted by MHonArc 2.6.19+ http://listengine.tuxfamily.org/