Skip to content

Syntax highlighting spans where the end condition depends on the begin condition #330

Answered by siegfriedpammer
khhelland asked this question in Q&A
Discussion options

You must be logged in to vote

The grammar you are working with is too complex for regular expressions. You will have to implement your own lexer-based highlighting based on IHighlighter.

See https://github.com/icsharpcode/SharpDevelop/blob/master/src/AddIns/BackendBindings/CSharpBinding/Project/Src/CSharpSemanticHighlighter.cs for an example of a semantic highlighter for C#.

Hope this helps!

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by khhelland
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants
Converted from issue

This discussion was converted from issue #309 on December 20, 2021 11:09.