PowerArgs.Cli.SimpleSyntaxHighlighter.AddKeyword C# (CSharp) Method

AddKeyword() public method

Registers a keyword with the highlighter.
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 void AddKeyword(string keyword, ConsoleColor? fg = null, ConsoleColor? bg = null, StringComparison comparison = StringComparison.InvariantCulture)
        {
            TokenHighlighters.Add(new KeywordHighlighter(keyword, fg, bg, comparison));
        }