File tree Expand file tree Collapse file tree 2 files changed +2
-3
lines changed
crates/terminal-colorsaurus/src Expand file tree Collapse file tree 2 files changed +2
-3
lines changed Original file line number Diff line number Diff line change 99//! * Background and foreground color detection.
1010//! * Uses a fast and reliable heuristic to detect if the terminal supports color querying.
1111//! * *Correct* perceived lightness calculation.
12- //! * Works on Windows (*soon* ).
12+ //! * Works on Windows (starting with Windows Terminal v1.22 ).
1313//! * Safely restores the terminal from raw mode even if the library errors or panicks.
1414//! * Does not send any escape sequences if `TERM=dumb`.
1515//! * Works even if all of stderr, stdout and stdin are redirected.
Original file line number Diff line number Diff line change 33[ ![ Docs] ( https://img.shields.io/docsrs/terminal-colorsaurus/latest )] ( https://docs.rs/terminal-colorsaurus )
44[ ![ Crate Version] ( https://img.shields.io/crates/v/terminal-colorsaurus )] ( https://crates.io/crates/terminal-colorsaurus )
55
6-
76Determines the background and foreground color of the terminal
87using the ` OSC 10 ` and ` OSC 11 ` escape codes.
98
109This library helps answer the question * «Is this terminal dark or light?»* .
1110
12- Windows is unfortunately [ not supported ] ( ./doc/windows.md ) .
11+ Works in all major terminals including Windows Terminal (starting with v1.22 ).
1312
1413## Example
1514``` rust,no_run
You can’t perform that action at this time.
0 commit comments