sammdot/rtfcre

Support lookahead translations

Opened this issue · 0 comments

Regular expression lookahead translations are now supported in Plover 4.0.0-dev8, allowing translations to change depending on the following text. Add a new control word \cxplvrlap (LookAhead Pattern) to specify the lookahead pattern, and then \cxplvrlam (LookAhead Match) for the text that will be used as the translation when the lookahead matches.

Plover syntax:

{=(?i)t/true/false}
{:if_next_matches:(?i)t/true/false}

Proposed RTF syntax:

false{\*\cxplvrlap (?i)t}{\*\cxplvrlam true}

This would allow steno engines that do not support lookaheads to automatically default to the false (i.e. lookahead does not match) translation.