AtkStateSet

AtkStateSet — An AtkStateSet determines a component's state set.

Synopsis




AtkStateSet* atk_state_set_new              (void);
gboolean    atk_state_set_is_empty          (AtkStateSet *set);
gboolean    atk_state_set_add_state         (AtkStateSet *set,
                                             AtkStateType type);
void        atk_state_set_add_states        (AtkStateSet *set,
                                             AtkStateType *types,
                                             gint n_types);
void        atk_state_set_clear_states      (AtkStateSet *set);
gboolean    atk_state_set_contains_state    (AtkStateSet *set,
                                             AtkStateType type);
gboolean    atk_state_set_contains_states   (AtkStateSet *set,
                                             AtkStateType *types,
                                             gint n_types);
gboolean    atk_state_set_remove_state      (AtkStateSet *set,
                                             AtkStateType type);
AtkStateSet* atk_state_set_and_sets         (AtkStateSet *set,
                                             AtkStateSet *compare_set);
AtkStateSet* atk_state_set_or_sets          (AtkStateSet *set,
                                             AtkStateSet *compare_set);
AtkStateSet* atk_state_set_xor_sets         (AtkStateSet *set,
                                             AtkStateSet *compare_set);

Description

An AtkStateSet determines a component's state set. It is composed of a set of AtkStates.

Details

atk_state_set_new ()

AtkStateSet* atk_state_set_new              (void);

Creates a new empty state set.

Returns : a new AtkStateSet

atk_state_set_is_empty ()

gboolean    atk_state_set_is_empty          (AtkStateSet *set);

Checks whether the state set is empty, i.e. has no states set.

set : an AtkStateType
Returns : TRUE if set has no states set, otherwise FALSE

atk_state_set_add_state ()

gboolean    atk_state_set_add_state         (AtkStateSet *set,
                                             AtkStateType type);

Add a new state for the specified type to the current state set if it is not already present.

set : an AtkStateSet
type : an AtkStateType
Returns : TRUE if the state for type is not already in set.

atk_state_set_add_states ()

void        atk_state_set_add_states        (AtkStateSet *set,
                                             AtkStateType *types,
                                             gint n_types);

Add the states for the specified types to the current state set.

set : an AtkStateSet
types : an array of AtkStateType
n_types : The number of elements in the array

atk_state_set_clear_states ()

void        atk_state_set_clear_states      (AtkStateSet *set);

Removes all states from the state set.

set : an AtkStateSet

atk_state_set_contains_state ()

gboolean    atk_state_set_contains_state    (AtkStateSet *set,
                                             AtkStateType type);

Checks whether the state for the specified type is in the specified set.

set : an AtkStateSet
type : an AtkStateType
Returns : TRUE if type is the state type is in set.

atk_state_set_contains_states ()

gboolean    atk_state_set_contains_states   (AtkStateSet *set,
                                             AtkStateType *types,
                                             gint n_types);

Checks whether the states for all the specified types are in the specified set.

set : an AtkStateSet
types : an array of AtkStateType
n_types : The number of elements in the array
Returns : TRUE if all the states for type are in set.

atk_state_set_remove_state ()

gboolean    atk_state_set_remove_state      (AtkStateSet *set,
                                             AtkStateType type);

Removes the state for the specified type from the state set.

set : an AtkStateSet
type : an AtkType
Returns : TRUE if type was the state type is in set.

atk_state_set_and_sets ()

AtkStateSet* atk_state_set_and_sets         (AtkStateSet *set,
                                             AtkStateSet *compare_set);

Constructs the intersection of the two sets, returning NULL if the intersection is empty.

set : an AtkStateSet
compare_set : another AtkStateSet
Returns : a new AtkStateSet which is the intersection of the two sets.

atk_state_set_or_sets ()

AtkStateSet* atk_state_set_or_sets          (AtkStateSet *set,
                                             AtkStateSet *compare_set);

Constructs the union of the two sets.

set : an AtkStateSet
compare_set : another AtkStateSet
Returns : a new AtkStateSet which is the union of the two sets, returning NULL is empty.

atk_state_set_xor_sets ()

AtkStateSet* atk_state_set_xor_sets         (AtkStateSet *set,
                                             AtkStateSet *compare_set);

Constructs the exclusive-or of the two sets, returning NULL is empty. The set returned by this operation contains the states in exactly one of the two sets.

set : an AtkStateSet
compare_set : another AtkStateSet
Returns : a new AtkStateSet which contains the states which are in exactly one of the two sets.