From b9e8935037fac6a99fba2bb449ae656dabb5fee7 Mon Sep 17 00:00:00 2001 From: Matthias Clasen Date: Thu, 16 Jul 2020 20:27:00 -0400 Subject: [PATCH] docs: Document GtkBitsetIter --- gtk/gtkbitset.c | 7 +++---- gtk/gtkbitset.h | 9 +++++++++ 2 files changed, 12 insertions(+), 4 deletions(-) diff --git a/gtk/gtkbitset.c b/gtk/gtkbitset.c index 6f29e59757..b4d8abb113 100644 --- a/gtk/gtkbitset.c +++ b/gtk/gtkbitset.c @@ -27,20 +27,19 @@ * SECTION:gtkbitset * @title: GtkBitset * @short_description: Sets of integers - * @see_also: GtkSelectionModel + * @see_also: #GtkSelectionModel * * #GtkBitset is a data structure for representing a set of unsigned integers. * Another name for this data structure is "bitmap". * - * This version is based on [roaring bitmaps](https://roaringbitmap.org/). + * The current implemenation is based on [roaring bitmaps](https://roaringbitmap.org/). * * A bitset allows adding a set of integers and provides support for set operations * like unions, intersections and checks for equality or if a value is contained * in the set. #GtkBitset also contains various functions to query metadata about * the bitset, such as the minimum or maximum values or its size. * - * The fastest way to iterate values in a bitset is #GtkBitsetIter which allows - * quick iteration of all the values in a bitset. + * The fastest way to iterate values in a bitset is #GtkBitsetIter. * * The main use case for #GtkBitset is implementing complex selections for * #GtkSelectionModel. diff --git a/gtk/gtkbitset.h b/gtk/gtkbitset.h index 19528ef55e..e54291cb91 100644 --- a/gtk/gtkbitset.h +++ b/gtk/gtkbitset.h @@ -130,6 +130,15 @@ void gtk_bitset_splice (GtkBitset guint removed, guint added); +/** + * GtkBitsetIter: + * + * An opaque, stack-allocated struct for iterating + * over the elements of a #GtkBitset. Before a GtkBitsetIter + * can be used, it needs to be initialized with + * gtk_bitset_iter_init_first(), gtk_bitset_iter_init_last() + * or gtk_bitset_iter_init_at(). + */ typedef struct {gpointer private_data[10]; } GtkBitsetIter; GDK_AVAILABLE_IN_ALL