
Unit
CPPHilit (add U suffix for Unicode version).
Declaration (partial)
type
TCustomExtHighlighter = class(TPlusHighlighter);
TCPPHighlighter = class(TCustomExtHighlighter);
Description
TCPPHighlighter is a non-visual component to dynamically highlight the text of a TPlusMemo according to the C++ syntax. You can set the highlighting properties of various elements and individual keywords at design time or at run time.
To use this component, place a TCPPHighlighter on a form or datamodule, set your TPlusMemo.Highlighter property to point to it, et voilà, C++ keywords are turned colored, underlined, bolded, as you want.
Key properties
Run-time only
| CommentMultiLine | A THighlightInfo object to control highlighting of multiline comments (/*...*/). | |
| CommentSingleLine | A THighlightInfo object to control highlighting of single line comments (//...). | |
| CPPKeywords | ||
| A THighlightInfo object to control highlighting of all C++ keywords as a whole. | ||
| Directives | A THighlightInfo object to control highlighting of directives (#...). | |
| KeywordsOvr | An object type property to control highlighting of individual keywords. | |
| Numbers | A THighlightInfo object to control highlighting of numbers. | |
| Strings | A THighlightInfo object to control highlighting of string constants ("..."). | |
| SubHighlighter | A TPlusHighighter object for further syntax highlighting, ex: urls within comments. |