summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMatthias Clasen <mclasen@redhat.com>2021-02-15 21:59:09 -0500
committerMatthias Clasen <mclasen@redhat.com>2021-02-15 22:19:58 -0500
commit77105c6f02a5f06c95430dcb7dfd1dede3a52ffc (patch)
treed8e73e99d56552311fc7e84670c6fc1e482fb5b0
parent286c85b9097e4a0e00c85535935164a3251cebcd (diff)
downloadpango-77105c6f02a5f06c95430dcb7dfd1dede3a52ffc.tar.gz
Trick g-ir-scanner
g-ir-scanner's handling of #defines is really rudimentary, so we have to trick it to pick up PANGO_ATTR_TO_TEXT_END as a constant with value 0, and then override the value with an annotation. See https://gitlab.gnome.org/GNOME/gobject-introspection/-/issues/369
-rw-r--r--pango/pango-attributes.h7
1 files changed, 4 insertions, 3 deletions
diff --git a/pango/pango-attributes.h b/pango/pango-attributes.h
index dd38aee2..025a6e2e 100644
--- a/pango/pango-attributes.h
+++ b/pango/pango-attributes.h
@@ -267,16 +267,17 @@ typedef enum {
*
* Since: 1.24
*/
+#define PANGO_ATTR_INDEX_FROM_TEXT_BEGINNING 0
+
/**
- * PANGO_ATTR_INDEX_TO_TEXT_END:
+ * PANGO_ATTR_INDEX_TO_TEXT_END: (value 4294967295)
*
* This value can be used to set the end_index member of a #PangoAttribute
* such that the attribute covers to the end of the text.
*
* Since: 1.24
*/
-#define PANGO_ATTR_INDEX_FROM_TEXT_BEGINNING 0
-#define PANGO_ATTR_INDEX_TO_TEXT_END G_MAXUINT
+#define PANGO_ATTR_INDEX_TO_TEXT_END (G_MAXUINT + 0)
/**
* PangoAttribute: