diff options
author | Matthias Clasen <mclasen@redhat.com> | 2021-12-18 19:25:21 -0500 |
---|---|---|
committer | Matthias Clasen <mclasen@redhat.com> | 2021-12-18 22:26:32 -0500 |
commit | cd54bd4c1e2368cb1de1d3c98b609cf802e849aa (patch) | |
tree | 45ccfa9bdf5f2c4ce28dd8822ce7d2af809ea38a | |
parent | 8ba9827171379cf7c2db8fe4d9d884907937554f (diff) | |
download | pango-cd54bd4c1e2368cb1de1d3c98b609cf802e849aa.tar.gz |
Improve line width accounting
We want to avoid trading chars for hyphens
in the margin beyond the set width.
Fixes: #646
-rw-r--r-- | pango/pango-layout.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/pango/pango-layout.c b/pango/pango-layout.c index a133afe6..3f11d5b0 100644 --- a/pango/pango-layout.c +++ b/pango/pango-layout.c @@ -4234,7 +4234,7 @@ retry_break: if (break_num_chars == item->num_chars || new_break_width + extra_width <= state->remaining_width || - new_break_width + extra_width <= break_width + break_extra_width) + new_break_width + extra_width < break_width + break_extra_width) { DEBUG1 ("accept breakpoint %d: %d + %d <= %d + %d", num_chars, new_break_width, extra_width, break_width, break_extra_width); |