summaryrefslogtreecommitdiff
path: root/pango
diff options
context:
space:
mode:
authorMatthias Clasen <mclasen@redhat.com>2022-01-20 22:06:32 -0500
committerMatthias Clasen <mclasen@redhat.com>2022-01-20 22:10:57 -0500
commitdd8e718e1997fba05d79e8bce48c7267ab274176 (patch)
tree17b127703bd7fde633e26e83b0e1242487ed4949 /pango
parent2e056820e77d9b8575d3888ac20a9a0879e530c4 (diff)
downloadpango-dd8e718e1997fba05d79e8bce48c7267ab274176.tar.gz
Fix allow_breaks handlingfix-allow-breaks
handling of segmentation attributes can introduce line breaks, after we removed them in allow_breaks handling. Change the order to handle allow_breaks last, so this doesn't happen. Update affected tests.
Diffstat (limited to 'pango')
-rw-r--r--pango/break.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/pango/break.c b/pango/break.c
index 9027d6d6..05ec97c9 100644
--- a/pango/break.c
+++ b/pango/break.c
@@ -2110,9 +2110,6 @@ break_attrs (const char *text,
pango_attr_list_insert (&hyphens, pango_attribute_copy (attr));
}
- tailored |= handle_allow_breaks (text, length, &allow_breaks, offset,
- log_attrs, log_attrs_len);
-
tailored |= handle_words (text, length, &words, offset,
log_attrs, log_attrs_len);
@@ -2122,6 +2119,9 @@ break_attrs (const char *text,
tailored |= handle_hyphens (text, length, &hyphens, offset,
log_attrs, log_attrs_len);
+ tailored |= handle_allow_breaks (text, length, &allow_breaks, offset,
+ log_attrs, log_attrs_len);
+
_pango_attr_list_destroy (&allow_breaks);
_pango_attr_list_destroy (&words);
_pango_attr_list_destroy (&sentences);