Class: Clutter::LayoutManager

Inherits:
GObject::InitiallyUnowned
  • Object
show all
Defined in:
(unknown)

Overview

The Clutter::LayoutManagerClass structure contains only private data and should be accessed using the provided API

Instance Method Summary collapse

Instance Method Details

#allocate(container, allocation, flags) ⇒ nil

Allocates the children of container given an area

See also clutter_actor_allocate()

Parameters:

  • container (Clutter::Container)

    the Clutter::Container using manager

  • allocation (Clutter::ActorBox)

    the Clutter::ActorBox containing the allocated area of container

  • flags (Clutter::AllocationFlags)

    the allocation flags

Returns:

  • (nil)

#animation_progressFloat

Retrieves the progress of the animation, if one has been started by clutter_layout_manager_begin_animation()

The returned value has the same semantics of the Clutter::Alpha:alpha value

Returns:

  • (Float)

    the progress of the animation

#begin_animation(duration, mode) ⇒ Clutter::Alpha

Begins an animation of duration milliseconds, using the provided easing mode

The easing mode can be specified either as a Clutter::AnimationMode or as a logical id returned by clutter_alpha_register_func()

The result of this function depends on the manager implementation

Parameters:

  • duration (Integer)

    the duration of the animation, in milliseconds

  • mode (Clutter::gulong)

    the easing mode of the animation

Returns:

  • (Clutter::Alpha)

    The Clutter::Alpha created by the layout manager; the returned instance is owned by the layout manager and should not be unreferenced

#child_get(container, actor, first_property, array) ⇒ nil

Retrieves the values for a list of properties out of the Clutter::LayoutMeta created by manager and attached to the child of a container

Parameters:

  • container (Clutter::Container)

    a Clutter::Container using manager

  • actor (Clutter::Actor)

    a Clutter::Actor child of container

  • first_property (String)

    the name of the first property

  • array (Array)

    a list of property name and return location for the value pairs

Returns:

  • (nil)

#child_get_property(container, actor, property_name, value) ⇒ nil

Gets a property on the Clutter::LayoutMeta created by manager and attached to a child of container

The #GValue must already be initialized to the type of the property and has to be unset with g_value_unset() after extracting the real value out of it

Parameters:

  • container (Clutter::Container)

    a Clutter::Container using manager

  • actor (Clutter::Actor)

    a Clutter::Actor child of container

  • property_name (String)

    the name of the property to get

  • value (GObject::Value)

    a #GValue with the value of the property to get

Returns:

  • (nil)

#child_set(container, actor, first_property, array) ⇒ nil

Sets a list of properties and their values on the Clutter::LayoutMeta associated by manager to a child of container

Languages bindings should use clutter_layout_manager_child_set_property() instead

Parameters:

  • container (Clutter::Container)

    a Clutter::Container using manager

  • actor (Clutter::Actor)

    a Clutter::Actor child of container

  • first_property (String)

    the first property name

  • array (Array)

    a list of property name and value pairs

Returns:

  • (nil)

#child_set_property(container, actor, property_name, value) ⇒ nil

Sets a property on the Clutter::LayoutMeta created by manager and attached to a child of container

Parameters:

  • container (Clutter::Container)

    a Clutter::Container using manager

  • actor (Clutter::Actor)

    a Clutter::Actor child of container

  • property_name (String)

    the name of the property to set

  • value (GObject::Value)

    a #GValue with the value of the property to set

Returns:

  • (nil)

#container=(container) ⇒ nil

If the Clutter::LayoutManager sub-class allows it, allow adding a weak reference of the container using manager from within the layout manager

The layout manager should not increase the reference count of the container

Parameters:

Returns:

  • (nil)

#end_animationnil

Ends an animation started by clutter_layout_manager_begin_animation()

The result of this call depends on the manager implementation

Returns:

  • (nil)

#find_child_property(name) ⇒ GObject::ParamSpec

Retrieves the GParam::Spec for the layout property name inside the Clutter::LayoutMeta sub-class used by manager

Parameters:

  • name (String)

    the name of the property

Returns:

  • (GObject::ParamSpec)

    a GParam::Spec describing the property, or nil if no property with that name exists. The returned GParam::Spec is owned by the layout manager and should not be modified or freed

#get_child_meta(container, actor) ⇒ Clutter::LayoutMeta

Retrieves the Clutter::LayoutMeta that the layout manager associated to the actor child of container, eventually by creating one if the Clutter::LayoutManager supports layout properties

Parameters:

Returns:

  • (Clutter::LayoutMeta)

    a Clutter::LayoutMeta, or nil if the Clutter::LayoutManager does not have layout properties. The returned layout meta instance is owned by the Clutter::LayoutManager and it should not be unreferenced

#get_preferred_height(container, for_width, min_height_p, nat_height_p) ⇒ nil

Computes the minimum and natural heights of the container according to manager.

See also clutter_actor_get_preferred_height()

Parameters:

  • container (Clutter::Container)

    the Clutter::Container using manager

  • for_width (Clutter::gfloat)

    the width for which the height should be computed, or -1

  • min_height_p (Clutter::gfloat)

    return location for the minimum height of the layout, or nil

  • nat_height_p (Clutter::gfloat)

    return location for the natural height of the layout, or nil

Returns:

  • (nil)

#get_preferred_width(container, for_height, min_width_p, nat_width_p) ⇒ nil

Computes the minimum and natural widths of the container according to manager.

See also clutter_actor_get_preferred_width()

Parameters:

  • container (Clutter::Container)

    the Clutter::Container using manager

  • for_height (Clutter::gfloat)

    the height for which the width should be computed, or -1

  • min_width_p (Clutter::gfloat)

    return location for the minimum width of the layout, or nil

  • nat_width_p (Clutter::gfloat)

    return location for the natural width of the layout, or nil

Returns:

  • (nil)

#layout_changednil

Emits the Clutter::LayoutManager::layout-changed signal on manager

This function should only be called by implementations of the Clutter::LayoutManager class

Returns:

  • (nil)

#list_child_properties(n_pspecs) ⇒ Array<GObject::ParamSpec>

Retrieves all the GParam::Specs for the layout properties stored inside the Clutter::LayoutMeta sub-class used by manager

Parameters:

  • n_pspecs (Integer)

    return location for the number of returned GParam::Specs

Returns:

  • (Array<GObject::ParamSpec>)

    the newly-allocated, nil-terminated array of GParam::Specs. Use g_free() to free the resources allocated for the array