GooCanvas.CanvasItemModelIface¶
Fields¶
Name |
Type |
Access |
Description |
---|---|---|---|
add_child |
r |
adds a child. |
|
animation_finished |
r |
signal emitted when the model’s animation has finished. |
|
base_iface |
r |
||
changed |
r |
signal emitted when the model has changed. |
|
child_added |
r |
signal emitted when a child is added. |
|
child_moved |
r |
signal emitted when a child is moved in the stacking order. |
|
child_notify |
r |
signal emitted when a child property has changed. |
|
child_removed |
r |
signal emitted when a child is removed. |
|
create_item |
r |
creates a default canvas item to view the model. |
|
get_child |
r |
returns the child at the given index. |
|
get_child_property |
r |
gets a child property of a given child model, e.g. the “row” or “column” property of a model in a |
|
get_n_children |
r |
returns the number of children of the model. |
|
get_parent |
r |
gets the model’s parent. |
|
get_style |
r |
gets the model’s style. |
|
get_transform |
r |
gets the model’s transformation matrix. |
|
move_child |
r |
moves a child up or down the stacking order. |
|
remove_child |
r |
removes a child. |
|
set_child_property |
r |
sets a child property for a given child model. |
|
set_parent |
r |
sets the model’s parent. |
|
set_style |
r |
sets the model’s style. |
|
set_transform |
r |
sets the model’s transformation matrix. |
Methods¶
None
Details¶
- class GooCanvas.CanvasItemModelIface¶
#GooCanvasItemModelIFace holds the virtual methods that make up the
GooCanvas.CanvasItemModel
interface.Simple item models only need to implement the get_parent(), set_parent() and create_item() methods.
Items that support transforms should also implement get_transform() and set_transform(). Items that support styles should implement get_style() and set_style().
Container items must implement get_n_children() and get_child(). Containers that support dynamic changes to their children should implement add_child(), move_child() and remove_child(). Layout containers like
GooCanvas.CanvasTable
may implement get_child_property() and set_child_property().