Use chunk-wise DisplayMap iteration when laying out lines

This commit is contained in:
Max Brunsfeld
2021-05-20 12:47:08 +02:00
committed by Antonio Scandurra
parent a9583d0074
commit c62a679e12
4 changed files with 101 additions and 111 deletions
+2 -2
View File
@@ -114,7 +114,7 @@ pub fn prev_word_boundary(
}
prev_c = Some(c);
column += 1;
column += c.len_utf8() as u32;
}
Ok(boundary)
}
@@ -135,7 +135,7 @@ pub fn next_word_boundary(
*point.row_mut() += 1;
*point.column_mut() = 0;
} else {
*point.column_mut() += 1;
*point.column_mut() += c.len_utf8() as u32;
}
prev_c = Some(c);
}