Search Results for

    Show / Hide Table of Contents

    Class SyntaxHighlightingTools

    Syntax highlighting tools

    Inheritance
    object
    SyntaxHighlightingTools
    Namespace: Terminaux.Reader.Highlighting
    Assembly: Terminaux.dll
    Syntax
    public static class SyntaxHighlightingTools

    Properties

    | Edit this page View Source

    HighlighterNames

    All installed highlighter names

    Declaration
    public static string[] HighlighterNames { get; }
    Property Value
    Type Description
    string[]
    | Edit this page View Source

    Highlighters

    All installed highlighters

    Declaration
    public static SyntaxHighlighting[] Highlighters { get; }
    Property Value
    Type Description
    SyntaxHighlighting[]

    Methods

    | Edit this page View Source

    Exists(string)

    Checks to see if a highlighter exists or not

    Declaration
    public static bool Exists(string highlighter)
    Parameters
    Type Name Description
    string highlighter

    A specific highlighter to check

    Returns
    Type Description
    bool

    True if found; false otherwise.

    | Edit this page View Source

    ExistsBuiltin(string)

    Checks to see if a highlighter is a built-in or not

    Declaration
    public static bool ExistsBuiltin(string highlighter)
    Parameters
    Type Name Description
    string highlighter

    A specific highlighter to check

    Returns
    Type Description
    bool

    True if found; false otherwise.

    | Edit this page View Source

    GetComponent(string)

    Gets the default highlighter

    Declaration
    public static SyntaxHighlightingComponent GetComponent(string componentName)
    Parameters
    Type Name Description
    string componentName

    Component name

    Returns
    Type Description
    SyntaxHighlightingComponent
    Exceptions
    Type Condition
    TerminauxException
    | Edit this page View Source

    GetComponent(string, string)

    Gets the default highlighter

    Declaration
    public static SyntaxHighlightingComponent GetComponent(string highlighter, string componentName)
    Parameters
    Type Name Description
    string highlighter

    Highlighter name

    string componentName

    Component name

    Returns
    Type Description
    SyntaxHighlightingComponent
    Exceptions
    Type Condition
    TerminauxException
    | Edit this page View Source

    GetComponent(SyntaxHighlighting?, string)

    Gets the highlighter

    Declaration
    public static SyntaxHighlightingComponent GetComponent(SyntaxHighlighting? highlighter, string componentName)
    Parameters
    Type Name Description
    SyntaxHighlighting highlighter

    Highlighter

    string componentName

    Component name

    Returns
    Type Description
    SyntaxHighlightingComponent
    Exceptions
    Type Condition
    TerminauxException
    | Edit this page View Source

    GetHighlighter()

    Gets the default highlighter for the current read. Returns null if no reader is present.

    Declaration
    public static SyntaxHighlighting? GetHighlighter()
    Returns
    Type Description
    SyntaxHighlighting
    Exceptions
    Type Condition
    TerminauxException
    | Edit this page View Source

    GetHighlighter(string)

    Gets the highlighter

    Declaration
    public static SyntaxHighlighting GetHighlighter(string highlighter)
    Parameters
    Type Name Description
    string highlighter

    Highlighter name

    Returns
    Type Description
    SyntaxHighlighting
    Exceptions
    Type Condition
    TerminauxException
    | Edit this page View Source

    GetHighlighterFromJson(string)

    Gets a highlighter from its JSON representation

    Declaration
    public static SyntaxHighlighting? GetHighlighterFromJson(string json)
    Parameters
    Type Name Description
    string json

    Highlighter JSON contents

    Returns
    Type Description
    SyntaxHighlighting

    A highlighter info containing JSON representation

    Exceptions
    Type Condition
    TerminauxException
    | Edit this page View Source

    GetHighlighterToJson()

    Gets a JSON representation of the highlighter

    Declaration
    public static string GetHighlighterToJson()
    Returns
    Type Description
    string

    A string containing the JSON representation of a highlighter

    Exceptions
    Type Condition
    TerminauxException
    | Edit this page View Source

    GetHighlighterToJson(string)

    Gets a JSON representation of the highlighter

    Declaration
    public static string GetHighlighterToJson(string highlighter)
    Parameters
    Type Name Description
    string highlighter

    Highlighter name to save to JSON

    Returns
    Type Description
    string

    A string containing the JSON representation of a highlighter

    Exceptions
    Type Condition
    TerminauxException
    | Edit this page View Source

    GetHighlighterToJson(SyntaxHighlighting?)

    Gets a JSON representation of the highlighter

    Declaration
    public static string GetHighlighterToJson(SyntaxHighlighting? highlighter)
    Parameters
    Type Name Description
    SyntaxHighlighting highlighter

    Highlighter to save to JSON

    Returns
    Type Description
    string

    A string containing the JSON representation of a highlighter

    Exceptions
    Type Condition
    TerminauxException
    | Edit this page View Source

    RegisterHighlighter(SyntaxHighlighting)

    Registers a highlighter

    Declaration
    public static void RegisterHighlighter(SyntaxHighlighting highlighter)
    Parameters
    Type Name Description
    SyntaxHighlighting highlighter

    Highlighter information

    | Edit this page View Source

    UnregisterHighlighter(string)

    Unregisters a highlighter

    Declaration
    public static void UnregisterHighlighter(string highlighter)
    Parameters
    Type Name Description
    string highlighter

    Highlighter information

    • Edit this page
    • View Source
    In this article
    Back to top Generated by DocFX