Crosstermion is a utility crate to unify some types of both crates, allowing to easily build apps that use the leaner termion
crate on unix systems, but resort to crossterm on windows systems.
Currently provided facilities are:
- a
Key
type an aninput_stream
(async) to receive key presses - an
AltenrativeRawTerminal
which marries an alternative screen with raw mode - a way to create a
tui
ortui-react
terminal with either the crossterm or the termion backend.
Features
All features work additively, but in case they are mutually exclusive, for instance
in case of tui-react
and tui
, or crossterm
and termion
, the more general one will be chosen.
- mutually exclusive
- crossterm
- provides
Key
conversion support fromcrossbeam::event::KeyEvent
and anAlternativeRawTerminal
- provides a threaded key input channel
- additive
- input-thread
- Adds input handling by spawning a thread providing input via
crossbeam
channels (which can be selected on)
- Adds input handling by spawning a thread providing input via
- input-async
- adds native async capabilites to crossterm, which works without spawning an extra thread thanks to
mio
.
- adds native async capabilites to crossterm, which works without spawning an extra thread thanks to
- input-thread
- provides
- termion
- provides
Key
conversion support fromtermion::event::Key
and anAlternativeRawTerminal
- provides a threaded key input channel
- additive
- input-thread
- Adds input handling by spawning a thread providing input via crossbeam channels (which can be selected on)
- input-async
- Spawn a thread and provide input events via a futures Stream
- input-thread
- provides
- crossterm
- mutually exclusive
- _using
tui_
(mutually exclusive)- tui-termion
- combines
tui
withtermion
and provides atui::Terminal
withtermion
backend
- combines
- tui-crossterm
- combines
tui
withcrossterm
and provides atui::Terminal
withcrossterm
backend
- combines
- tui-termion
- using
tui-react
(mutually exclusive)- tui-react-termion
- combines
tui-react
withcrossterm
and provides atui::Terminal
withcrossterm
backend
- combines
- tui-react-crossterm
- combines
tui-react
withcrossterm
and provides atui::Terminal
withcrossterm
backend
- combines
- tui-react-termion
- _using