Skip to main content

extract_ansi_styles

Function extract_ansi_styles 

Source
pub fn extract_ansi_styles(text: &str) -> Vec<(usize, HashMap<String, String>)>
Expand description

Extract structured style information from ANSI-formatted text

§Arguments

  • text - The text with ANSI escape sequences

§Returns

A vector of (position, styles) where styles is a map of active styles