highlighting indepedent of lexer

SyntaxEditor for WPF Forum

Posted 10 years ago by Martin de Jong - Statistics Netherlands
Version: 9.2.0510
Avatar
I made a snippeteditor, which uses my Mergable lexer, so syntax highlighting works there (too). As you know, snippet text containts declarations independent of the tokens made by the lexer. Sometimes/often they even exists inside tokens.

To mark/highlight the declaration i was thinking of an adornment service, which independent of the tokene can highlight/select the declaration.

An other option is to let do the lexer the work, and make special tags of the declarations.

Which option do you suggest for the best result?

Thank you in advance

Regards

Martin

Comments (1)

Posted 10 years ago by Actipro Software Support - Cleveland, OH, USA
Avatar
Hi Martin,

Generally for template or snippet sort of files, we recommend letting the lexer do it all. And use two languages. Our HTML language definition shows how you can transition from one language to another since it does HTML to CSS, JScript, ASP, etc.


Actipro Software Support

The latest build of this product (v2019.1 build 0683) was released 1 month ago, which was after the last post in this thread.

Add Comment

Please log in to a validated account to post comments.