Original Post
Hi, I'm writing a syntax highlighter for C++/CLI and so far, all of the one-line highlighting (single keywords, strings, etc.) is working fine. I would also like to be able to highlight multi-line comments, preprocessor macros and other things that can extend beyond one line. Right now I just check to see how many characters have been entered or deleted (when the text is changed) and use the cursor position to determine which lines need to have their syntax re-highlighted. I can't apply the same technique to multi-line targets, as I'm not sure how to tell where highlighting should begin and/or end. I've Googled around, but I haven't been able to find anything that really goes into depth on this subject. If anyone knows of any articles, links, or info that they can post, it is much appreciated!