From a84c9cdda7f6a4115d22983124bb70327ffbe785 Mon Sep 17 00:00:00 2001 From: "C. McEnroe" Date: Wed, 2 Sep 2020 01:55:44 -0400 Subject: Fix line wrapping in various ways Never split a codepoint, don't set wrapping point unless we're not already wrapping, wrap on any unicode whitespace, only clear rest of line if still on the same line... --- ui.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'ui.c') diff --git a/ui.c b/ui.c index 3ecea9f..89dd4da 100644 --- a/ui.c +++ b/ui.c @@ -457,7 +457,9 @@ static void windowUpdate(void) { if (line->heat < Cold && window->ignore) continue; wmove(main, y, 0); styleAdd(main, line->str); - wclrtoeol(main); + int ny, nx; + getyx(main, ny, nx); + if (ny == y) wclrtoeol(main); if (!y--) break; } -- cgit 1.4.1