Syntax Highlighting

General questions about using TextPad

Moderators: AmigoJack, bbadmin, helios, Bob Hansen, MudGuard

Post Reply
Steve Gleason

Syntax Highlighting

Post by Steve Gleason »

I am creating a new syntax file but I am having problems where a variable contains a period or a dollar sign (. $). If the variable name contains one of the keywords such as DATA and the variable name is TOP.DATA, the DATA portion of the variable is highlighted.

How do I stop that from happening?
Keith MacDonald

RE: Syntax Highlighting

Post by Keith MacDonald »

Steve,

Try adding a dummy keyword, such as "a.b". That will force TextPad to treat "." as part of keywords, so it will look for a match on "TOP.DATA", rather than "TOP" and "DATA". Obviously, this can cause side effects, if keywords can actually be bounded by "." in your language.

Keith MacDonald
Helios Software Solutions
Post Reply