Property | Type | Description | |
---|---|---|---|
keyword | string |
Method | Description | |
---|---|---|
KeywordHighlighter ( string keyword, ConsoleColor fg = null, ConsoleColor bg = null, System.StringComparison comparison = StringComparison.InvariantCulture ) : System |
Creates the highlighter.
|
|
ShouldBeHighlighted ( |
Returns true if the keyword is matched, false otherwise
|
public KeywordHighlighter ( string keyword, ConsoleColor fg = null, ConsoleColor bg = null, System.StringComparison comparison = StringComparison.InvariantCulture ) : System | ||
keyword | string | The keyword to highlight whenever it is found |
fg | ConsoleColor | The foreground color of this highlighter. If null, the console default is used. |
bg | ConsoleColor | The background color of this highlighter. If null, the console default is used. |
comparison | System.StringComparison | determines how strings are compared. By default the comparison is case sensitive |
return | System |
public ShouldBeHighlighted ( |
||
readerContext | context from the reader | |
highlighterContext | context about the current token | |
return | bool |