[−][src]Function mksvg::text::wrap
pub fn wrap(s: &str, mx: usize) -> Vec<String>
wrap text to a max line lencth of mx, returning a Vec of String
use mksvg::text::wrap; assert_eq!(&wrap("hello everybody",6),&["hello","everyb-","ody"]); assert_eq!(&wrap("hi to the people i know",6),&["hi to","the","people","i know"]);