From a9a7224301ff3627d54dacd86b152f9950e58a79 Mon Sep 17 00:00:00 2001 From: lancebord Date: Sun, 8 Mar 2026 19:25:46 -0400 Subject: off by one fix for some word wrapping --- src/tui/ui.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/tui/ui.rs') diff --git a/src/tui/ui.rs b/src/tui/ui.rs index 9edf5af..0fc1ec9 100644 --- a/src/tui/ui.rs +++ b/src/tui/ui.rs @@ -147,7 +147,7 @@ fn count_wrapped_lines(lines: &[Line], width: usize) -> usize { for word in full_text.split_inclusive(' ') { let word_width = UnicodeWidthStr::width(word); - if current_width + word_width > width { + if current_width > 0 && current_width + word_width > width { row_count += 1; current_width = word_width; } else { -- cgit v1.2.3-59-g8ed1b