This class can syntax-highlight a document. It automatically manages invalidating the highlighting when the document changes.
Creates a new DocumentHighlighter instance.
Opens a group of HighlightLine(Int32) calls. It is not necessary to call this method before calling HighlightLine(Int32), however, doing so can make the highlighting much more performant in some cases (e.g. the C# semantic highlighter in SharpDevelop will re-use the resolver within a highlighting group).
Gets the default text color.
Disposes the document highlighter.
Gets the document that this DocumentHighlighter is highlighting.
Closes the currently opened group of HighlightLine(Int32) calls.
Allows an Object to attempt to free resources and perform other cleanup operations before the Object is reclaimed by garbage collection.(Inherited from Object.)
Gets the stack of active colors (the colors associated with the active spans) at the end of the specified line. -> GetColorStack(1) returns the colors at the start of the second line.
Serves as a hash function for a particular type.(Inherited from Object.)
Retrieves the HighlightingColor with the specified name. Returns null if no color matching the name is found.
Gets the span stack at the end of the specified line. -> GetSpanStack(1) returns the spans at the start of the second line.
Gets the Type of the current instance.(Inherited from Object.)
Notification when the highlighter detects that the highlighting state at the beginning of the specified lines has changed. fromLineNumber and toLineNumber are both inclusive; the common case of a single-line change is represented by fromLineNumber == toLineNumber. During highlighting, the highlighting of line X will cause this event to be raised for line X+1 if the highlighting state at the end of line X has changed from its previous state. This event may also be raised outside of the highlighting process to signalize that changes to external data (not the document text; but e.g. semantic information) require a re-highlighting of the specified lines.
Highlights the specified document line.
Gets/sets the the initial span stack of the document. Default value is Empty.
Invalidates all stored highlighting info. When the document changes, the highlighting is invalidated automatically, this method needs to be called only when there are changes to the highlighting rule set.
Creates a shallow copy of the current Object.(Inherited from Object.)
Is called when the highlighting state at the end of the specified line has changed.
Enforces a highlighting state update (triggering the HighlightingStateChanged event if necessary) for all lines up to (and inclusive) the specified line number.
Assembly: ICSharpCode.AvalonEdit (Module: ICSharpCode.AvalonEdit.dll) Version: 184.108.40.20638