Open QKekos opened 6 months ago
IMO, there is no reason for a user to use both Sequence Transform and Autocorrect. Every* valid Autocorrect rule can be used directly as a Sequence Transform rule.
As I said multiple times - autocorrect and st have very different goals
Regard implementation details - I believe that we should just process_autocorrect(keycode)
each time st types out something, and do the same for process_autocorrect(KC_BACKSPACE)
each time we delete something
I thought about this a bit again. I think the best solution is to allow the user to specify a second dictionary with rules that they don't want the training mode to trigger on.
These rules would go in their own trie that is appended on the end of the existing trie (so that we can still reference them with a single offset) and the rules matched would process them but rules search would ignore them.
Bonus, a user could put most of their rules in here and just have training mode trigger on a small subset, which could be nice for people trying to learn them one block at a time, or people with huge rulesets that are seeing performance issues on search.
Autocorrection uses very similar approach with
process_autocorrect(keycode, record)
, so make our send strings actually queue the keys for autocorrect too + maybe dequeueing if we find how