Skip to main content

wrap_ranges

Function wrap_ranges 

Source
pub fn wrap_ranges<'a, O>(text: &str, width_or_options: O) -> Vec<Range<usize>>
where O: Into<Options<'a>>,
Expand description

Returns byte-ranges into text for each wrapped line, including trailing whitespace and a +1 sentinel byte. Used by the textarea cursor-position logic.