Expand description
Color utilities for VT Code
This module provides color manipulation capabilities using anstyle, which offers low-level ANSI styling with RGB and 256-color support.
Structs§
Functions§
- black
- Apply black color to text
- blend_
colors - Blend two RGB colors
- blink
- Apply blinking styling to text
- blue
- Apply blue color to text
- bold
- Apply bold styling to text
- color_
from_ hex - Create an RGB color from hex string
- color_
to_ rgb - Convert an ANSI color to RGB, if possible
- contrasting_
color - Get a contrasting color (black or white) for better readability
- custom_
style - Combine multiple color and style operations
- cyan
- Apply cyan color to text
- desaturate_
color - Create a desaturated version of a color
- dimmed
- Apply dimmed styling to text
- green
- Apply green color to text
- is_
light_ color - Determine if a color is light (for contrast calculations)
- italic
- Apply italic styling to text
- purple
- Apply purple color to text
- red
- Apply red color to text
- reversed
- Apply reversed styling to text
- rgb
- Apply custom RGB color to text
- strikethrough
- Apply strikethrough styling to text
- style
- Style wrapper for console::style compatibility
- underline
- Apply underline styling to text
- white
- Apply white color to text
- yellow
- Apply yellow color to text