on master help sign in
This char_index is unused
commit01b1a62e2c6187b7406b20a38c8a371bd053dc63 authorBlaž Hrastnik <blaz@mxxn.io> dateSun 27 Jun 2021, 23:09 (5 years ago) parent4edfac2
1 file changed−4
helix-term/src/ui/editor.rs−4
helix-term/src/ui/editor.rs−4
@@ -250,8 +250,6 @@ impl EditorView {
250250 // and paint the new cursor.
251251 // We could keep a single resizable surface on the View for that.
252252
253− let mut char_index = start;
254−
255253 // iterate over range char by char
256254 for grapheme in RopeGraphemes::new(text) {
257255 let out_of_bounds = visual_x < view.first_col as u16
@@ -311,8 +309,6 @@ impl EditorView {
311309
312310 visual_x += width;
313311 }
314−
315− char_index += grapheme.chars().count();
316312 }
317313 }
318314 }