Skip to main content

display_width

Function display_width 

Source
pub fn display_width(s: &str) -> usize
Expand description

Terminal display width of s, ignoring ANSI escape sequences.

Uses [char_width] per character so that characters which unicode_width under-reports are counted correctly.