Guide API
Skip to main content

xterm256_to_xterm16

Function xterm256_to_xterm16 

Source
pub const fn xterm256_to_xterm16(idx: u8) -> u8
Expand description

Look up the nearest xterm-16 index for an xterm-256 index.

For indices 0..=15 the result is the identity (the first 16 xterm-256 entries are the xterm-16 palette).