VirtualTerminal

A Terminal implementation backed by Swing.

This allows us to provide a cross-platform UI window that can always run a Kotter program, which can be especially useful backup if, for some reason, a normal ANSI-featured terminal cannot be created.

An instance cannot be created manually. See VirtualTerminal.create instead.

Types

Link copied to clipboard
object Companion

Properties

Link copied to clipboard
open override val height: Int

The height of the terminal.

Link copied to clipboard
open override val width: Int

The width of the terminal.

Functions

Link copied to clipboard
open override fun clear()

Clear the current terminal, removing all text written there so far.

Link copied to clipboard
open override fun close()

Shut down this terminal, releasing any resources.

Link copied to clipboard
open override fun read(): SharedFlow<Int>

Return a hot SharedFlow which will get triggered with characters read in by the underlying terminal, often input typed in by a user.

Link copied to clipboard
open override fun write(text: String)

Write some text to the underlying terminal.