C# Класс PowerArgs.Cli.FixedHighlightTokenHighlighter

A highlighter that has a fixed foreground and background color. Most highlighters derive from this base.
Наследование: ITokenHighlighter
Показать файл Открыть проект

Открытые методы

Метод Описание
FixedHighlightTokenHighlighter ( ConsoleColor fg = null, ConsoleColor bg = null ) : System

Creates a new highlighter using the given colors

ShouldBeHighlighted ( RichCommandLineContext readerContext, HighlighterContext highlighterContext ) : bool

Determines if this highlighter should highlight the current token with this highlighter's foreground and background colors.

Описание методов

FixedHighlightTokenHighlighter() публичный Метод

Creates a new highlighter using the given colors
public FixedHighlightTokenHighlighter ( ConsoleColor fg = null, ConsoleColor bg = null ) : System
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.
Результат System

ShouldBeHighlighted() публичный абстрактный Метод

Determines if this highlighter should highlight the current token with this highlighter's foreground and background colors.
public abstract ShouldBeHighlighted ( RichCommandLineContext readerContext, HighlighterContext highlighterContext ) : bool
readerContext RichCommandLineContext context from the reader
highlighterContext HighlighterContext context about the current token
Результат bool