So let's say I have a trigger set to 'Jo' and I highlight that name. But when Joe or Joseph comes up, the Jo is highlighted too. How can I make it so only when just 'Jo' by itself comes up, it will highlight that text?
Matching only Smaller word w/i a larger one (trigger)
Posted by Silencher on Tue 09 Jul 2013 04:07 AM — 2 posts, 13,569 views.
Regular expressions
- Regular expressions (as used in triggers and aliases) are documented on the Regular expression tips forum page.
- Also see how Lua string matching patterns work, as documented on the Lua string.find page.
You need a "word boundary" assertion ( \b )