From 62ad205dbf99cb0384f864fe6e3f4ebe52de3257 Mon Sep 17 00:00:00 2001 From: Jean-Marc Lasgouttes Date: Wed, 15 Dec 2021 11:19:18 +0100 Subject: [PATCH] Avoid duplication of words on screen When giving up splitting a word sequence because it is not enough to make the row short enough, make sure to clean up properly. --- src/Row.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/src/Row.cpp b/src/Row.cpp index db52b057dd..6d6d319194 100644 --- a/src/Row.cpp +++ b/src/Row.cpp @@ -585,6 +585,7 @@ Row::Elements Row::shortenIfNeeded(int const w, int const next_width) */ if (wid_brk + cit_brk->dim.wid < w && dim_.wid - (wid_brk + brk.dim.wid) >= next_width) { + tail.clear(); break; } end_ = brk.endpos;