Next: , Previous: ClutterConstraint, Up: Top


25 ClutterContainer

An interface for container actors

25.1 Overview

<clutter-container> is an interface implemented by <clutter-actor>, and it provides some common API for notifying when a child actor is added or removed, as well as the infrastructure for accessing child properties through <clutter-child-meta>.

Until Clutter 1.10, the <clutter-container> interface was also the public API for implementing container actors; this part of the interface has been deprecated: <clutter-container> has a default implementation which defers to <clutter-actor> the child addition and removal, as well as the iteration. See the documentation of <clutter-container-iface> for the list of virtual functions that should be overridden.

25.2 Usage

— Function: clutter-container-child-notify (self <clutter-container>) (child <clutter-actor>) (pspec <gparam>)
— Method: child-notify

Calls the clutter-container-iface.child-notify virtual function of <clutter-container>. The default implementation will emit the <"child-notify"> signal.

container
a <clutter-container>
child
a <clutter-actor>
pspec
a <gparam>

Since 1.6

— Function: clutter-container-create-child-meta (self <clutter-container>) (actor <clutter-actor>)
— Method: create-child-meta

Creates the <clutter-child-meta> wrapping actor inside the container, if the <"child-meta-type"> class member is not set to ‘G_TYPE_INVALID’.

This function is only useful when adding a <clutter-actor> to a <clutter-container> implementation outside of the <clutter-container>::add virtual function implementation.

Applications should not call this function.

container
a <clutter-container>
actor
a <clutter-actor>

Since 1.2

— Function: clutter-container-get-child-meta (self <clutter-container>) (actor <clutter-actor>) ⇒  (ret <clutter-child-meta>)
— Method: get-child-meta

Retrieves the <clutter-child-meta> which contains the data about the container specific state for actor.

container
a <clutter-container>
actor
a <clutter-actor> that is a child of container.
ret
the <clutter-child-meta> for the actor child of container or ‘#f’ if the specifiec actor does not exist or the container is not configured to provide <clutter-child-meta>s.

Since 0.8