Hi,
I've written a syntax file where some of the keywords have dashes in the middle, e.g. load-if-defined
but only the "if" in "load-if-defined" highlights ("if" is also a keyword).
I noticed the keywordchars syntax option is gone, and I saw in another post that Textpad works out what characters make up keywords from the syntax file. The only time dash is used is in keywords - it's not an operator or anything else.
Is there anything I can do about it?
Dashes in keywords
Moderators: AmigoJack, bbadmin, helios, MudGuard
-
Mark Schnitzius
Re: Dashes in keywords
Go to
Configure | Preferences | Document Classes | <your document class> | Syntax | Other characters in words
and add the "-" dash character.
Configure | Preferences | Document Classes | <your document class> | Syntax | Other characters in words
and add the "-" dash character.
-
zillionsofgames
- Posts: 1
- Joined: Wed Aug 13, 2003 11:12 pm
Re: Dashes in keywords
I have the same problem. My language (for scripting game rules) supports dashes in keywords as well. I want to include this in a .syn file so every single user who has TextPad doesn't have to change a setting.
Now, there is a syntax file keyword called "KeyWordChars" that is undocumented in the latest help file. I tried adding "\-" (a dash in a regular expression) to the set of keyword chars, but for some reason this doesn't work.
Is there any way to do this in the .syn file?
Now, there is a syntax file keyword called "KeyWordChars" that is undocumented in the latest help file. I tried adding "\-" (a dash in a regular expression) to the set of keyword chars, but for some reason this doesn't work.
Is there any way to do this in the .syn file?