Crate tattoy_termwiz

Crate tattoy_termwiz 

Source
Expand description

§Terminal Wizardry

This is a rust crate that provides a number of support functions for applications interested in either displaying data to a terminal or in building a terminal emulator.

It is currently in active development and subject to fairly wild sweeping changes.

Included functionality:

  • Surface models a terminal display and its component Cells
  • Terminal attributes are aware of modern features such as True Color, Hyperlinks and will also support sixel and iterm style terminal graphics display.
  • Surfaces include a log of Changes and an API for consuming and applying deltas. This is a powerful building block for synchronizing screen instances.
  • Escape sequence parser decodes inscrutable escape sequences and gives them semantic meaning, making the code that uses them clearer. The decoded escapes can be re-encoded, allowing applications to start with the semantic meaning and emit the appropriate escape sequence without embedding obscure binary bytes.
  • Capabilities allows probing for terminal capabilities that may not be included in the system terminfo database, and overriding them in an embedding application.
  • Terminal trait provides an abstraction over unix style ttys and Windows style console APIs. Changes from Surface can be rendered to Terminals. Terminals allow decoding mouse and keyboard inputs in both blocking or non-blocking mode.
  • Widget trait allows composition of UI elements at a higher level.
  • LineEditor provides line editing facilities similar to those in the unix shell.

§Features

  • widgets - enables the widget layout and related traits
  • use_serde - makes a number of structs serde serializable

Re-exports§

pub use error::Context;
pub use error::Error;
pub use error::Result;
pub use wezterm_cell as cell;
pub use wezterm_surface as surface;
pub use wezterm_escape_parser as escape;

Modules§

caps
Terminal Capabilities
cellcluster
color
Colors for attributes
error
hyperlink
Handling hyperlinks. This gist describes an escape sequence for explicitly managing hyperlinks: https://gist.github.com/egmontkob/eb114294efbcd5adb1944c9f3cb5feda We use that as the foundation of our hyperlink support, and the game plan is to then implicitly enable the hyperlink attribute for a cell as we recognize linkable input text during print() processing.
input
This module provides an InputParser struct to help with parsing input received from a terminal.
istty
Making it a little more convenient and safe to query whether something is a terminal teletype or not. This module defines the IsTty trait and the is_tty method to return true if the item represents a terminal.
keymap
A datastructure for holding key map entries
lineedit
The LineEditor struct provides line editing facilities similar to those in the unix shell.
nerdfonts
render
terminal
An abstraction over a terminal device
tmux_cc
widgets

Macros§

bail
ensure
format_err