Have you checked if an issue already exists for this feature request?
What feature would you like added?
The goal is a simple (as possible) format for importing and exporting mappings and groups of mappings. The syntax can either be an officially defined schema for an existing data transfer format such as JSON or YAML, or a more specialized DSL.
- This format should be human-readable, so it can be authored outside the app and later imported.
- It should also be machine-writable, to allow generating mappings automatically based on definitions from arbitrary sources using simple scripting (the conversion itself is out of scope here).
- And of course, Key Mapper should be able to produce a valid file of this type for any mapping or group of mappings, such that reimporting it on the same (or another*) device reproduces it identically.
* Certain identifiers and parameters for triggers or actions will likely be dependent on the device Key Mapper is running on, and/or some other physical input device. The handling of these cases should be clearly defined, even if unsupported. Ideally unspecified references could be resolved during the import process, e.g. by giving each a name and letting the importing user manually specify it.
Rough specification
The exact requirements for this language will need to reflect the current feature set of Key Mapper's UI, and the addition of new features should probably be tracked with a version identifier in scripts. See particularly #988 for details.
First attempt to collect a set of requirements (subject to change):
Previous work
I'm unsure if a suitably similar format already exists. The first instinctual connection "AutoHotKey" uses a DSL specifically tailored for keystrokes (while Key Mapper supports many other trigger types) and with full scripting functionality (out of scope for this). Inspiration could still be taken from the syntax to define Hotkeys.
On the other hand, the XCompose format is simple and declarative, but likewise tailored to keyboard use and without support for complex actions or conditions.
App version
4.5.0-foss 271
Device model and manufacturer
as agnostic as possible
Extra info
Have you checked if an issue already exists for this feature request?
What feature would you like added?
The goal is a simple (as possible) format for importing and exporting mappings and groups of mappings. The syntax can either be an officially defined schema for an existing data transfer format such as JSON or YAML, or a more specialized DSL.
* Certain identifiers and parameters for triggers or actions will likely be dependent on the device Key Mapper is running on, and/or some other physical input device. The handling of these cases should be clearly defined, even if unsupported. Ideally unspecified references could be resolved during the import process, e.g. by giving each a name and letting the importing user manually specify it.
Rough specification
The exact requirements for this language will need to reflect the current feature set of Key Mapper's UI, and the addition of new features should probably be tracked with a version identifier in scripts. See particularly #988 for details.
First attempt to collect a set of requirements (subject to change):
Previous work
I'm unsure if a suitably similar format already exists. The first instinctual connection "AutoHotKey" uses a DSL specifically tailored for keystrokes (while Key Mapper supports many other trigger types) and with full scripting functionality (out of scope for this). Inspiration could still be taken from the syntax to define Hotkeys.
On the other hand, the XCompose format is simple and declarative, but likewise tailored to keyboard use and without support for complex actions or conditions.
App version
4.5.0-foss 271
Device model and manufacturer
as agnostic as possible
Extra info