Functions
hb_set_allocation_successful ()
hb_bool_t
hb_set_allocation_successful (const hb_set_t *set
);
Tests whether memory allocation for a set was successful.
Returns
true
if allocation succeeded, false otherwise
Since: 0.9.2
hb_set_clear ()
void
hb_set_clear (hb_set_t *set
);
Clears out the contents of a set.
Since: 0.9.2
hb_set_create ()
hb_set_t *
hb_set_create (void
);
Creates a new, initially empty set.
[Xconstructor]
Returns
The new hb_set_t.
[transfer full]
Since: 0.9.2
hb_set_destroy ()
void
hb_set_destroy (hb_set_t *set
);
Decreases the reference count on a set. When
the reference count reaches zero, the set is
destroyed, freeing all memory.
[skip]
Since: 0.9.2
hb_set_get_empty ()
hb_set_t *
hb_set_get_empty (void
);
Fetches the singleton empty hb_set_t.
Returns
The empty hb_set_t.
[transfer full]
Since: 0.9.2
hb_set_get_population ()
unsigned int
hb_set_get_population (const hb_set_t *set
);
Returns the number of elements in the set.
Returns
The population of set
Since: 0.9.7
hb_set_get_user_data ()
void *
hb_set_get_user_data (hb_set_t *set
,
hb_user_data_key_t *key
);
Fetches the user data associated with the specified key,
attached to the specified set.
[skip]
Returns
A pointer to the user data.
[transfer none]
Since: 0.9.2
hb_set_has ()
hb_bool_t
hb_set_has (const hb_set_t *set
,
hb_codepoint_t codepoint
);
Tests whether codepoint
belongs to set
.
Returns
true
if codepoint
is in set
, false otherwise
Since: 0.9.2
hb_set_intersect ()
void
hb_set_intersect (hb_set_t *set
,
const hb_set_t *other
);
Makes set
the intersection of set
and other
.
Since: 0.9.2
hb_set_is_empty ()
hb_bool_t
hb_set_is_empty (const hb_set_t *set
);
Tests whether a set is empty (contains no elements).
Returns
true
if set
is empty
Since: 0.9.7
hb_set_is_equal ()
hb_bool_t
hb_set_is_equal (const hb_set_t *set
,
const hb_set_t *other
);
Tests whether set
and other
are equal (contain the same
elements).
Returns
TRUE
if the two sets are equal, FALSE
otherwise.
Since: 0.9.7
hb_set_is_subset ()
hb_bool_t
hb_set_is_subset (const hb_set_t *set
,
const hb_set_t *larger_set
);
Tests whether set
is a subset of larger_set
.
Returns
TRUE
if the set
is a subset of (or equal to) larger_set
, FALSE
otherwise.
Since: 1.8.1
hb_set_next ()
hb_bool_t
hb_set_next (const hb_set_t *set
,
hb_codepoint_t *codepoint
);
Fetches the next element in set
that is greater than current value of codepoint
.
Set codepoint
to HB_SET_VALUE_INVALID
to get started.
Returns
true
if there was a next value, false otherwise
Since: 0.9.2
hb_set_previous ()
hb_bool_t
hb_set_previous (const hb_set_t *set
,
hb_codepoint_t *codepoint
);
Fetches the previous element in set
that is lower than current value of codepoint
.
Set codepoint
to HB_SET_VALUE_INVALID
to get started.
Returns
true
if there was a previous value, false otherwise
Since: 1.8.0
hb_set_previous_range ()
hb_bool_t
hb_set_previous_range (const hb_set_t *set
,
hb_codepoint_t *first
,
hb_codepoint_t *last
);
Fetches the previous consecutive range of elements in set
that
are greater than current value of last
.
Set first
to HB_SET_VALUE_INVALID
to get started.
Returns
true
if there was a previous range, false otherwise
Since: 1.8.0
hb_set_reference ()
hb_set_t *
hb_set_reference (hb_set_t *set
);
Increases the reference count on a set.
[skip]
Returns
The set.
[transfer full]
Since: 0.9.2
hb_set_set ()
void
hb_set_set (hb_set_t *set
,
const hb_set_t *other
);
Makes the contents of set
equal to the contents of other
.
Since: 0.9.2
hb_set_subtract ()
void
hb_set_subtract (hb_set_t *set
,
const hb_set_t *other
);
Subtracts the contents of other
from set
.
Since: 0.9.2
hb_set_symmetric_difference ()
void
hb_set_symmetric_difference (hb_set_t *set
,
const hb_set_t *other
);
Makes set
the symmetric difference of set
and other
.
Since: 0.9.2
hb_set_union ()
void
hb_set_union (hb_set_t *set
,
const hb_set_t *other
);
Makes set
the union of set
and other
.
Since: 0.9.2