Options
All
  • Public
  • Public/Protected
  • All
Menu

XTerm interfacing object.

Hierarchy

  • XTermInterface

Index

Constructors

constructor

  • Creates a new XTI.

    Parameters

    • term: any

      Xterm terminal [external]

    • color: any

      Color [external]

    • wnd: StandardWindow

      The window to use.

    Returns any

Properties

color

color: any

[external] Color.

term

term: any

[external] XTerm terminal.

Accessors

hasNewLine

  • get hasNewLine(): boolean
  • Has new line?

    Returns boolean

lastChars

  • get lastChars(): string
  • Gets the last chars.

    Returns string

Methods

clear

  • clear(): void
  • Clears the terminal

    Returns void

escapeANSI

  • escapeANSI(text: string): string
  • Escapes ANSI text.

    Parameters

    • text: string

      The text to escape.

    Returns string

onData

  • onData(): void
  • [internal]

    Returns void

pause

  • pause(): Promise<void>
  • Pauses the terminal.

    Returns Promise<void>

print

  • Prints text.

    Parameters

    • text: string

      The text to print.

    • Optional opts: TermWriteOpts

      The options to use.

    Returns void

printError

  • Prints an error.

    Parameters

    • text: string

      The text to print.

    • Optional opts: TermWriteOpts

      The options to use.

    Returns void

println

  • Prints text (with newline).

    Parameters

    • text: string

      The text to print.

    • Optional opts: TermWriteOpts

      The options to use.

    Returns void

printlnEscaped

  • Prints text (escaped, with newline).

    Parameters

    • text: string

      The text to print.

    • Optional opts: TermWriteOpts

      The options to use.

    Returns void

prompt

  • prompt(question: string, allowCtrlC?: boolean): Promise<void>
  • Creates a prompt.

    Parameters

    • question: string

      The question to ask.

    • Optional allowCtrlC: boolean

      Whether to allow CTRL+C to break out of it. Default = false.

    Returns Promise<void>

write

  • Prints text.

    Parameters

    • text: string

      The text to print.

    • Optional opts: TermWriteOpts

      The options to use.

    Returns void

writeln

  • Prints text (with newline).

    Parameters

    • text: string

      The text to print.

    • Optional opts: TermWriteOpts

      The options to use.

    Returns void

Generated using TypeDoc