Scoop API

scoop:scoop.terminal:0.1.0

scoop.terminal

API

  • interface Command

    A terminal command that writes its ANSI representation to a text destination. Serialization alone does not flush output or query terminal capabilities.

  • struct CursorPosition

    A zero-based cursor cell coordinate.

  • enum DeviceAttributeKind

    Selects primary capability attributes or secondary identification attributes.

  • struct Print

    Writes the content's ToString result as supplied, without escaping terminal control sequences.

  • enum StandardStream

    Selects a process standard endpoint for terminal detection.

  • class TerminalDisconnectedException

    Terminal input ended before another user event could be returned.

  • class TerminalQueryTimeoutException

    A terminal query did not obtain its matching reply before the requested deadline.

  • class TerminalSession

    An owned synchronous terminal session with input parsing, queries, byte output, and raw-mode restoration. Operations on one session must not overlap.

  • struct TerminalSize

    Terminal dimensions in character cells and platform-reported pixels.

  • function cursorPosition

    Queries the terminal's zero-based cursor position within a bounded wait.

  • function deviceAttributes

    Queries the selected device-attribute family and returns its numeric parameters.

  • function execute

    Writes the commands in order, then flushes the byte sink.

  • function isTerminal

    Tests whether the selected standard endpoint refers to a terminal.

  • function keyboardEnhancementFlags

    Queries enhanced-keyboard support; None means the terminal completed the capability probe without reporting flags.

  • function queue

    Writes the commands in order without flushing the destination.

  • function supportsKeyboardEnhancement

    Returns whether the terminal reports enhanced-keyboard flags during the bounded query.

  • function toAnsiString

    Serializes this command into an in-memory string without terminal I/O.

  • function withRawMode

    Runs the block with raw mode enabled and restores the previous raw-mode state on normal or exceptional exit.