| Clutter Reference Manual | ||||
|---|---|---|---|---|
| Top | Description | Object Hierarchy | Properties | ||||
enum ClutterBinAlignment; struct ClutterBinLayout; struct ClutterBinLayoutClass; ClutterLayoutManager * clutter_bin_layout_new (ClutterBinAlignment x_align,ClutterBinAlignment y_align); void clutter_bin_layout_set_alignment (ClutterBinLayout *self,ClutterActor *child,ClutterBinAlignment x_align,ClutterBinAlignment y_align); void clutter_bin_layout_get_alignment (ClutterBinLayout *self,ClutterActor *child,ClutterBinAlignment *x_align,ClutterBinAlignment *y_align); void clutter_bin_layout_add (ClutterBinLayout *self,ClutterActor *child,ClutterBinAlignment x_align,ClutterBinAlignment y_align);
"x-align" ClutterBinAlignment : Read / Write "y-align" ClutterBinAlignment : Read / Write
ClutterBinLayout is a layout manager which implements the following policy:
Figure 4. Bin layout
The image shows a ClutterBinLayout with three layers:
a background ClutterCairoTexture, set to fill on both the X
and Y axis; a ClutterTexture, set to center on both the X and
Y axis; and a ClutterRectangle, set to CLUTTER_BIN_ALIGNMENT_END
on both the X and Y axis.

ClutterBinLayout is available since Clutter 1.2
typedef enum {
CLUTTER_BIN_ALIGNMENT_FIXED,
CLUTTER_BIN_ALIGNMENT_FILL,
CLUTTER_BIN_ALIGNMENT_START,
CLUTTER_BIN_ALIGNMENT_END,
CLUTTER_BIN_ALIGNMENT_CENTER
} ClutterBinAlignment;
ClutterBinAlignment has been deprecated since version 1.12 and should not be used in newly-written code. Use ClutterActorAlign and the ClutterActor
API instead
The alignment policies available on each axis for ClutterBinLayout
| Fixed position alignment; the ClutterBinLayout will honour the fixed position provided by the actors themselves when allocating them | |
| Fill the allocation size | |
| Position the actors at the top or left side of the container, depending on the axis | |
| Position the actors at the bottom or right side of the container, depending on the axis | |
| Position the actors at the center of the container, depending on the axis |
Since 1.2
struct ClutterBinLayout;
The ClutterBinLayout structure contains only private data and should be accessed using the provided API
Since 1.2
struct ClutterBinLayoutClass {
};
The ClutterBinLayoutClass structure contains only private data and should be accessed using the provided API
Since 1.2
ClutterLayoutManager * clutter_bin_layout_new (ClutterBinAlignment x_align,ClutterBinAlignment y_align);
Creates a new ClutterBinLayout layout manager
|
the default alignment policy to be used on the horizontal axis |
|
the default alignment policy to be used on the vertical axis |
Returns : |
the newly created layout manager |
Since 1.2
void clutter_bin_layout_set_alignment (ClutterBinLayout *self,ClutterActor *child,ClutterBinAlignment x_align,ClutterBinAlignment y_align);
clutter_bin_layout_set_alignment has been deprecated since version 1.12 and should not be used in newly-written code. Use the "x-align" and
"y-align" properties of ClutterActor instead.
Sets the horizontal and vertical alignment policies to be applied
to a child of self
If child is NULL then the x_align and y_align values will
be set as the default alignment policies
|
a ClutterBinLayout |
|
a child of container. [allow-none]
|
|
the horizontal alignment policy to be used for the child
inside container
|
|
the vertical aligment policy to be used on the child
inside container
|
Since 1.2
void clutter_bin_layout_get_alignment (ClutterBinLayout *self,ClutterActor *child,ClutterBinAlignment *x_align,ClutterBinAlignment *y_align);
clutter_bin_layout_get_alignment has been deprecated since version 1.12 and should not be used in newly-written code. Use the "x-align" and the
"y-align" properties of ClutterActor instead.
Retrieves the horizontal and vertical alignment policies for
a child of self
If child is NULL the default alignment policies will be returned
instead
|
a ClutterBinLayout |
|
a child of container. [allow-none]
|
|
return location for the horizontal alignment policy. [out][allow-none] |
|
return location for the vertical alignment policy. [out][allow-none] |
Since 1.2
void clutter_bin_layout_add (ClutterBinLayout *self,ClutterActor *child,ClutterBinAlignment x_align,ClutterBinAlignment y_align);
clutter_bin_layout_add has been deprecated since version 1.12 and should not be used in newly-written code. Use clutter_actor_add_child() instead.
Adds a ClutterActor to the container using self and
sets the alignment policies for it
This function is equivalent to clutter_container_add_actor()
and clutter_layout_manager_child_set_property() but it does not
require a pointer to the ClutterContainer associated to the
ClutterBinLayout
|
a ClutterBinLayout |
|
a ClutterActor |
|
horizontal alignment policy for child
|
|
vertical alignment policy for child
|
Since 1.2
"x-align" property"x-align" ClutterBinAlignment : Read / Write
ClutterBinLayout:x-align has been deprecated since version 1.12 and should not be used in newly-written code. Use the "x-expand" and the
"x-align" properties on ClutterActor instead.
The default horizontal alignment policy for actors managed by the ClutterBinLayout
Default value: CLUTTER_BIN_ALIGNMENT_CENTER
Since 1.2
"y-align" property"y-align" ClutterBinAlignment : Read / Write
ClutterBinLayout:y-align has been deprecated since version 1.12 and should not be used in newly-written code. Use the "y-expand" and the
"y-align" properties on ClutterActor instead.
The default vertical alignment policy for actors managed by the ClutterBinLayout
Default value: CLUTTER_BIN_ALIGNMENT_CENTER
Since 1.2