summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEmmanuele Bassi <ebassi@gnome.org>2019-08-02 11:16:28 +0100
committerEmmanuele Bassi <ebassi@gnome.org>2019-08-02 11:16:28 +0100
commitf5cd8b93e0f3b463ba4f660cce2db86dfef0a165 (patch)
tree41ec38e98c68def2147e7ac50e6417b88eb8414d
parentbd6dcbcc2b6103b1102c84e219034ba55ec80fe5 (diff)
downloadpango-f5cd8b93e0f3b463ba4f660cce2db86dfef0a165.tar.gz
Add a boxed type for PangoAttrIterator
Makes it usable by language bindings, and avoids warnings when generating introspection data. We already have the necessary public API, we're just missing a GType for it.
-rw-r--r--pango/pango-attributes.c5
-rw-r--r--pango/pango-attributes.h3
2 files changed, 8 insertions, 0 deletions
diff --git a/pango/pango-attributes.c b/pango/pango-attributes.c
index b5e0f77c..2f02e264 100644
--- a/pango/pango-attributes.c
+++ b/pango/pango-attributes.c
@@ -1835,6 +1835,11 @@ pango_attr_list_get_attributes (PangoAttrList *list)
return g_slist_copy_deep (list->attributes, (GCopyFunc)pango_attribute_copy, NULL);
}
+G_DEFINE_BOXED_TYPE (PangoAttrIterator,
+ pango_attr_iterator,
+ pango_attr_iterator_copy,
+ pango_attr_iterator_destroy)
+
/**
* pango_attr_list_get_iterator:
* @list: a #PangoAttrList
diff --git a/pango/pango-attributes.h b/pango/pango-attributes.h
index d46ce6f0..b9ab6459 100644
--- a/pango/pango-attributes.h
+++ b/pango/pango-attributes.h
@@ -588,6 +588,9 @@ PangoAttrList *pango_attr_list_filter (PangoAttrList *list,
PANGO_AVAILABLE_IN_1_44
GSList *pango_attr_list_get_attributes (PangoAttrList *list);
+PANGO_AVAILABLE_IN_1_44
+GType pango_attr_iterator_get_type (void) G_GNUC_CONST;
+
PANGO_AVAILABLE_IN_ALL
PangoAttrIterator *pango_attr_list_get_iterator (PangoAttrList *list);