Expand description

A widget based terminal ui rendering library.

This crate provides an abstraction over terminal manipulation in the form of the Widget trait. It also provides some default widgets available in widgets.

While this crate was built for the requestty crate and other crates which implement the Prompt trait in requestty, it can be used otherwise as well.


This crate currently supports 2 backends:

The different backends can be enabled using the features of the same name.


pub use widgets::Widget;


A module to represent a terminal and operations on it.

A module for handling key events

A module to describe regions of the screen that can be rendered to.

A module to control the looks of text.

Special characters used for prompts/widgets.

A module containing the in-built widgets and types required by them


assert_backend_snapshotcrossterm or termion

A testing utility to assert visual equality with TestBackend.


A ui runner which implements the render cycle.


The errors that can occur in requestty.

What to do after receiving Esc

The state of a prompt on validation.


This trait should be implemented by all ‘root’ widgets.

Type Definitions

The requestty result type.