[pango/misc-cleanups: 4/5] Improve line width accounting
- From: Matthias Clasen <matthiasc src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [pango/misc-cleanups: 4/5] Improve line width accounting
- Date: Sun, 19 Dec 2021 03:27:01 +0000 (UTC)
commit cd54bd4c1e2368cb1de1d3c98b609cf802e849aa
Author: Matthias Clasen <mclasen redhat com>
Date: Sat Dec 18 19:25:21 2021 -0500
Improve line width accounting
We want to avoid trading chars for hyphens
in the margin beyond the set width.
Fixes: #646
pango/pango-layout.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
---
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);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]