summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSebastian Thiel <sebastian.thiel@icloud.com>2020-03-30 00:41:19 +0800
committerSebastian Thiel <sebastian.thiel@icloud.com>2020-03-30 00:41:19 +0800
commit12fd9936abfce74df3b5e3b005d7eff7e7d8204d (patch)
tree86cfdd1fa149c5a477205fb8776852335446d6b6
parente8c00b709fe1d4470d80e086ba615febba0dfd24 (diff)
cleanup
-rw-r--r--tui-react/src/lib.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/tui-react/src/lib.rs b/tui-react/src/lib.rs
index 991e396..e0537a4 100644
--- a/tui-react/src/lib.rs
+++ b/tui-react/src/lib.rs
@@ -82,11 +82,11 @@ pub fn draw_text_without_ellipsis_nowrap<'a>(
) -> u16 {
let s = style.into();
let t = text.as_ref();
- let mut graphemes = t.graphemes(true);
+ let graphemes = t.graphemes(true);
let mut total_width = 0;
{
let mut x_offset = 0;
- for (g, mut x) in graphemes.by_ref().zip(bound.left()..bound.right()) {
+ for (g, mut x) in graphemes.zip(bound.left()..bound.right()) {
let width = g.width();
total_width += width;