Commit graph

12 commits

Author SHA1 Message Date
Marc Durdin
3eaaacd706 fix(developer): handle errors in .keyman-touch-layout file when loading
If the .keyman-touch-layout file has validation errors, Keyman Developer
will now report the first validation error in the message window, rather
than silently closing the whole keyboard editor. The
.keyman-touch-layout file will be loaded in Code view, and once the
first validation error is addressed, switching to Design view will
report the next error.

For future improvement:
* reporting multiple validation errors
* reporting line number of error

Fixes: #15242
Test-bot: skip
2025-11-27 05:50:36 +01:00
Marc Durdin
0b17c632a0 fix(developer): handle exceptions loading .keyman-touch-layout files
If file is unreadable or contains invalid encoding, show a message
instead of crashing.

Build-bot: skip
Test-bot: skip
2025-10-30 15:22:47 +01:00
Marc Durdin
4090a46363
Merge pull request #11720 from keymanapp/fix/developer/11719-handle-missing-osk-when-importing-windows-keyboard
fix(developer): handle missing OSK when importing a Windows keyboard into a touch-only project
2024-06-13 10:01:00 +10:00
Marc Durdin
8123f4be56 refactor(developer): rename TouchLayoutToVisualKeyboardConverter to VisualKeyboardToTouchLayoutConverter
No change in functionality. But class and unit name now match what they
actually do.
2024-06-06 12:37:38 +07:00
Marc Durdin
33d7dca155 fix(developer): prevent two touch layout editors opening for the same file
The keyboard editor has a complex edit state machine, which has
grown a lot over time. This is a minimal patch to address one specific
edge case scenario on that state machine, without any attempt to improve
the state machine overall. The biggest change here is bubbling failure
up to the main form so that it can destroy (aka Release, which is an
asynchronous destroy) the editor window if it fails to load completely.

Fixes: #11715
Fixes: KEYMAN-DEVELOPER-1JC
2024-06-06 10:45:44 +07:00
Marc Durdin
c02f5ab419 feat(developer): add 'default' property for longpress keys
Fixes #9430.

Adds a 'default' property to subkeys, only used by longpress-type
subkeys:

* Added property to schema and readers/writers
* Added property to touch layout validator
* Added editor for property to layout builder
2023-08-08 14:20:52 +07:00
Marc Durdin
d2fe2a61f9 fix(developer): patch from previous commit 2022-11-09 07:36:28 +11:00
Marc Durdin
6032181e18 feat(developer): rework displayHint to defaultHint
After a demo of the Touch Layout Editor @jahorton suggested using a
"default hint" model instead of the "display hint" from the design spec.
I liked this and have reworked the design accordingly. With the default
hint model, a source for the hint text can be specified, such as the
default longpress key, or a specific flick key. This can then be
overridden on a key level.

The hint input element now shows a placeholder to indicate the default
hint for the key, and if a hint has been customised for a given key, it
is shown in green on the key cap.

Changing the default hint does not impact any customised hints.
2022-07-14 10:58:59 +10:00
Marc Durdin
54a655e92e feat(developer): add hint and displayHint to touch layout validation and parsing 2022-07-14 10:58:55 +10:00
Marc Durdin
60dabb5284 feat(developer): add support for flick and multitap to compiler 2022-07-14 10:57:25 +10:00
Marc Durdin
268ba98219 feat(developer): Support new touch layout definitions in Delphi
Also minor tweaks to allow jquery-ui images to load, fixup for broken
file path for node.exe.
2022-07-14 10:55:01 +10:00
Marc Durdin
a160a5c709 chore(developer): move source files to /developer/src 2022-05-18 10:34:48 +10:00