Atk.StateSet - Classes - Atk 1.0 (original) (raw)
g Atk.StateSet Atk.StateSet GObject.Object GObject.Object GObject.Object->Atk.StateSet
Subclasses:
None
Methods¶
Inherited:
Structs:
class | new () |
---|---|
add_state (type) | |
add_states (types) | |
and_sets (compare_set) | |
clear_states () | |
contains_state (type) | |
contains_states (types) | |
is_empty () | |
or_sets (compare_set) | |
remove_state (type) | |
xor_sets (compare_set) |
Virtual Methods¶
Inherited:
Properties¶
None
Signals¶
Inherited:
Fields¶
Inherited:
Name | Type | Access | Description |
---|---|---|---|
parent | GObject.Object | r |
Class Details¶
class Atk.StateSet(**kwargs)¶
Bases:
Abstract:
No
Structure:
An Atk.StateSet contains the states of an object.
An Atk.StateSet is a read-only representation of the full set of #AtkStates that apply to an object at a given time. This set is not meant to be modified, but rather created when Atk.Object.ref_state_set() is called.
Returns:
a new Atk.StateSet
Return type:
Creates a new empty state set.
Parameters:
type (Atk.StateType) – an Atk.StateType
Returns:
True if the state for type is not already in self.
Return type:
Adds the state of the specified type to the state set if it is not already present.
Note that because an Atk.StateSet is a read-only object, this method should be used to add a state to a newly-created set which will then be returned byAtk.Object.ref_state_set. It should not be used to modify the existing state of an object. See also Atk.Object.notify_state_change.
Parameters:
types ([Atk.StateType]) – an array of Atk.StateType
Adds the states of the specified types to the state set.
Note that because an Atk.StateSet is a read-only object, this method should be used to add states to a newly-created set which will then be returned byAtk.Object.ref_state_set. It should not be used to modify the existing state of an object. See also Atk.Object.notify_state_change.
and_sets(compare_set)[source]¶
Parameters:
compare_set (Atk.StateSet) – another Atk.StateSet
Returns:
a new Atk.StateSet which is the intersection of the two sets.
Return type:
Constructs the intersection of the two sets, returning None if the intersection is empty.
Removes all states from the state set.
Parameters:
type (Atk.StateType) – an Atk.StateType
Returns:
True if type is the state type is in self.
Return type:
Checks whether the state for the specified type is in the specified set.
contains_states(types)[source]¶
Parameters:
types ([Atk.StateType]) – an array of Atk.StateType
Returns:
True if all the states for type are in self.
Return type:
Checks whether the states for all the specified types are in the specified set.
Returns:
True if self has no states set, otherwise False
Return type:
Checks whether the state set is empty, i.e. has no states set.
Parameters:
compare_set (Atk.StateSet) – another Atk.StateSet
Returns:
a new Atk.StateSet which is the union of the two sets, returning None is empty.
Return type:
Atk.StateSet or None
Constructs the union of the two sets.
Parameters:
type (Atk.StateType) – an #AtkType
Returns:
True if type was the state type is in self.
Return type:
Removes the state for the specified type from the state set.
Note that because an Atk.StateSet is a read-only object, this method should be used to remove a state to a newly-created set which will then be returned by Atk.Object.ref_state_set. It should not be used to modify the existing state of an object. See also Atk.Object.notify_state_change.
xor_sets(compare_set)[source]¶
Parameters:
compare_set (Atk.StateSet) – another Atk.StateSet
Returns:
a new Atk.StateSet which contains the states which are in exactly one of the two sets.
Return type:
Constructs the exclusive-or of the two sets, returning None is empty. The set returned by this operation contains the states in exactly one of the two sets.