Property | Type | Description | |
---|---|---|---|
EnsureHighlighted | bool |
Method | Description | |
---|---|---|
AddConditionalKeyword ( string keyword, Func |
Registers a keyword with the highlighter that should only be highlighted if some condition is true
|
|
AddKeyword ( string keyword, ConsoleColor fg = null, ConsoleColor bg = null, System.StringComparison comparison = StringComparison.InvariantCulture ) : void |
Registers a keyword with the highlighter.
|
|
AddRegex ( string regex, ConsoleColor fg = null, ConsoleColor bg = null ) : void |
Registers a regular expression with the highlighter. Tokens that exactly match the given regex will be highlighted.
|
|
AddTokenHighlighter ( ITokenHighlighter highlighter ) : void |
Registers a custom token highlighter
|
|
SetNumericHighlight ( ConsoleColor fg = null, ConsoleColor bg = null ) : void |
Lets you control how numeric values should be highlighted
|
|
SetQuotedStringLiteralHighlight ( ConsoleColor fg = null, ConsoleColor bg = null ) : void |
Lets you control how quoted string literals should be highlighted
|
|
SimpleSyntaxHighlighter ( ) : System |
Creates a new SimpleSyntaxHighlighter
|
|
TryHighlight ( |
The implementation of ISyntaxHighlighter that uses the configuration you've created to perform syntax highlighting.
|
Method | Description | |
---|---|---|
EnsureHighlighted ( Token token, |
public AddConditionalKeyword ( string keyword, Func |
||
keyword | string | The keyword that will conditionally be highlighted when found on the command line |
conditionEval | Func |
the conditional evaluation function |
fg | ConsoleColor | The foreground highlight color |
bg | ConsoleColor | The background highlight color |
comparison | System.StringComparison | Determines how strings are compared. |
return | void |
public AddKeyword ( string keyword, ConsoleColor fg = null, ConsoleColor bg = null, System.StringComparison comparison = StringComparison.InvariantCulture ) : void | ||
keyword | string | The keyword that will be highlighted when found on the command line |
fg | ConsoleColor | The foreground highlight color |
bg | ConsoleColor | The background highlight color |
comparison | System.StringComparison | Determines how strings are compared. |
return | void |
public AddRegex ( string regex, ConsoleColor fg = null, ConsoleColor bg = null ) : void | ||
regex | string | the regular expression pattern to search for |
fg | ConsoleColor | The foreground highlight color |
bg | ConsoleColor | The background highlight color |
return | void |
public AddTokenHighlighter ( ITokenHighlighter highlighter ) : void | ||
highlighter | ITokenHighlighter | the custom highlighter |
return | void |
public SetNumericHighlight ( ConsoleColor fg = null, ConsoleColor bg = null ) : void | ||
fg | ConsoleColor | The foreground highlight color |
bg | ConsoleColor | The background highlight color |
return | void |
public SetQuotedStringLiteralHighlight ( ConsoleColor fg = null, ConsoleColor bg = null ) : void | ||
fg | ConsoleColor | The foreground highlight color |
bg | ConsoleColor | The background highlight color |
return | void |
public TryHighlight ( |
||
readerContext | Context that is used internally | |
return | bool |