pinchord-5 Emit Invalid Strokes
Pinchord · pinchord.git · Tickets · Changelog
A Pinchord Ticket (Completed):
Ticket · History
Closed June 9, 2026, In pinchord-1 v28
Any stroke that contains a chord that is not in the dictionary will translate to {}, which is not added to the undo stack. This means that undoing after some strokes will actually delete the stroke before the one you meant to undo.
Currently, this means that you have to react to whether a stroke actually translated to anything before you can undo it, even if you realized in the middle of the stroke that it was invalid.
Implementation
This must be solved independently for Plover and Javelin, and will be shipped at the same time to keep parity.
Javelin
There is no way for a "fail" a javelin orthospelling
The reason this exists is that all Pinchord strokes are consumed by the Javelin orthospelling dictionary, thanks to this:
starters:
- {stroke: '', definition: '{}', mask: ''}
This means that an invalid stroke will still translate to {}.
To solve this, I think the best way would probably be to map all keys to something, so that something always gets emitted.
Probably the chord that is invalid, and the rest can translate properly?
Plover
I haven't looked at how to solve this with Plover, but Plover does have an easy way to fail lookup in a Python dictionary by raising an error.
If the solution is fully in the Javelin orthospelling dictionary then the same logic should work for the python dictionary object as well.