Dazzle.StateMachine¶
- Subclasses:
None
Methods¶
- Inherited:
- Structs:
class |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Virtual Methods¶
- Inherited:
Properties¶
Name |
Type |
Flags |
Short Description |
---|---|---|---|
r/w |
The current state of the machine. |
Signals¶
- Inherited:
Fields¶
- Inherited:
Name |
Type |
Access |
Description |
---|---|---|---|
parent_instance |
r |
Class Details¶
- class Dazzle.StateMachine(**kwargs)¶
- Bases:
- Abstract:
No
- Structure:
- classmethod new()¶
- Return type:
- add_binding(state, source_object, source_property, target_object, target_property, flags)¶
- add_propertyv(state, object, property, value)¶
- Parameters:
state (
str
) –property (
str
) –value (
GObject.Value
) –
- add_style(state, widget, style)¶
- Parameters:
state (
str
) –widget (
Gtk.Widget
) –style (
str
) –
- create_action(name)¶
- Parameters:
name (
str
) – the name of the action.- Returns:
A newly created
Gio.Action
.- Return type:
Creates a new
Gio.Action
with the name of name.Setting the state of this action will toggle the state of the state machine. You should use
GLib.Variant.new_string
() or similar to create the state.
- get_state()¶
- Returns:
The current state of the machine.
- Return type:
Gets the
Dazzle.StateMachine
:state
property. This is the name of the current state of the machine.
- is_state(state)¶
- Parameters:
- Returns:
True
if self is currently set to state.- Return type:
Checks to see if the current state of the
Dazzle.StateMachine
matches state.New in version 3.28.
- set_state(state)¶
- Parameters:
state (
str
) –
Sets the
Dazzle.StateMachine
:state
property.Registered state transformations will be applied during the state transformation.
If the transition results in a cyclic operation, the state will stop at the last state before the cycle was detected.