rustui
The simplest terminal UI library designed for Rust. Developed with Rust's ownership model and safety guarantees in mind.
Features
- Cross-platform: Works on Unix-like systems (Linux, macOS, etc.)
- Double Buffering: Efficient rendering with differential updates
- Rich Text Styling: Support for colors, attributes (bold, italic, underline, etc.)
- Non-blocking Input: Asynchronous keyboard input handling
- Thread-safe: Multi-threaded rendering and input processing
Quick Start
use *;
use ;
const RENDERING_RATE: Duration = from_millis; // ms
const INPUT_CAPTURING_RATE: Duration = from_millis; // ms
Example Applications
This repository includes a demo application that showcases the library's capabilities:
Hello World
Colors
Inputs
Tetris
Platform Support
Currently supports Unix-like systems:
- Linux
- macOS
- BSD variants
Windows support may be added in future versions.
Contributing
We sincerely appreciate your contribution to this crate. Please be sure to read the guidelines before contributing.
Development
# Clone the repository
# Build the library
# Run tests
# Run the demo
License
This project is licensed under the MIT License - see the LICENSE file for details.
Note: This library is designed for educational purposes and as a foundation for terminal-based applications. For production use, consider established libraries like crossterm
or ratatui-rs
depending on your needs.