Terminal Styling Library (src/style.rs)

vtcode · patches/crossterm/src/style.rs · rust · Apache-2.0
ui, cli, lang:rust, tag:knn-classified

Provides cross-platform utilities for applying colors and text attributes in terminal applications. Use this to build rich, styled command-line interfaces.

// Source: https://github.com/vinhnx/vtcode | License: Apache-2.0 | Copyright 2025 Vinh Nguyen
// Provided via justclaw.it.com; keep this notice with the code.
//! # Style
//!
//! The `style` module provides a functionality to apply attributes and colors on your text.
//!
//! This documentation does not contain a lot of examples. The reason is that it's fairly
//! obvious how to use this crate. Although, we do provide
//! [examples](https://github.com/crossterm-rs/crossterm/tree/master/examples) repository
//! to demonstrate the capabilities.
//!
//! ## Platform-specific Notes
//!
//! Not all features are supported on all terminals/platforms. You should always consult
//! platform-specific notes of the following types:
//!
//! * [Color](enum.Color.html#platform-specific-notes

... (truncated -- full source via MCP)

See the full source, get the GitHub permalink, and search for more like it.

Get a free API key