Top | ![]() |
![]() |
![]() |
![]() |
ClutterLayoutManager * | clutter_table_layout_new () |
void | clutter_table_layout_set_row_spacing () |
guint | clutter_table_layout_get_row_spacing () |
void | clutter_table_layout_set_column_spacing () |
guint | clutter_table_layout_get_column_spacing () |
gint | clutter_table_layout_get_row_count () |
gint | clutter_table_layout_get_column_count () |
void | clutter_table_layout_pack () |
void | clutter_table_layout_set_alignment () |
void | clutter_table_layout_get_alignment () |
void | clutter_table_layout_set_expand () |
void | clutter_table_layout_get_expand () |
void | clutter_table_layout_set_fill () |
void | clutter_table_layout_get_fill () |
void | clutter_table_layout_get_span () |
void | clutter_table_layout_set_span () |
void | clutter_table_layout_set_use_animations () |
gboolean | clutter_table_layout_get_use_animations () |
void | clutter_table_layout_set_easing_duration () |
guint | clutter_table_layout_get_easing_duration () |
void | clutter_table_layout_set_easing_mode () |
gulong | clutter_table_layout_get_easing_mode () |
guint | column-spacing | Read / Write |
guint | easing-duration | Read / Write |
gulong | easing-mode | Read / Write |
guint | row-spacing | Read / Write |
gboolean | use-animations | Read / Write |
enum | ClutterTableAlignment |
struct | ClutterTableLayout |
struct | ClutterTableLayoutClass |
The ClutterTableLayout is a ClutterLayoutManager implementing the following layout policy:
children are arranged in a table
each child specifies the specific row and column cell to appear;
a child can also set a span, and this way, take more than one cell both horizontally and vertically;
each child will be allocated to its natural size or, if set to expand, the available size;
if a child is set to fill on either (or both) axis, its allocation will match all the available size; the fill layout property only makes sense if the expand property is also set;
if a child is set to expand but not to fill then it is possible to control the alignment using the horizontal and vertical alignment layout properties.
It is possible to control the spacing between children of a
ClutterTableLayout by using clutter_table_layout_set_row_spacing()
and clutter_table_layout_set_column_spacing()
.
In order to set the layout properties when packing an actor inside a
ClutterTableLayout you should use the clutter_table_layout_pack()
function.
A ClutterTableLayout can use animations to transition between different values of the layout management properties; the easing mode and duration used for the animations are controlled by the “easing-mode” and “easing-duration” properties and their accessor functions.
ClutterTableLayout is available since Clutter 1.4
ClutterLayoutManager *
clutter_table_layout_new (void
);
Creates a new ClutterTableLayout layout manager
Since 1.4
void clutter_table_layout_set_row_spacing (ClutterTableLayout *layout
,guint spacing
);
Sets the spacing between rows of layout
Since 1.4
guint
clutter_table_layout_get_row_spacing (ClutterTableLayout *layout
);
Retrieves the spacing set using clutter_table_layout_set_row_spacing()
Since 1.4
void clutter_table_layout_set_column_spacing (ClutterTableLayout *layout
,guint spacing
);
Sets the spacing between columns of layout
Since 1.4
guint
clutter_table_layout_get_column_spacing
(ClutterTableLayout *layout
);
Retrieves the spacing set using clutter_table_layout_set_column_spacing()
Since 1.4
gint
clutter_table_layout_get_row_count (ClutterTableLayout *layout
);
Retrieve the current number rows in the layout
Since 1.4
gint
clutter_table_layout_get_column_count (ClutterTableLayout *layout
);
Retrieve the current number of columns in layout
Since 1.4
void clutter_table_layout_pack (ClutterTableLayout *layout
,ClutterActor *actor
,gint column
,gint row
);
Packs actor
inside the ClutterContainer associated to layout
at the given row and column.
layout |
||
actor |
||
column |
the column the |
|
row |
the row the |
Since 1.4
void clutter_table_layout_set_alignment (ClutterTableLayout *layout
,ClutterActor *actor
,ClutterTableAlignment x_align
,ClutterTableAlignment y_align
);
Sets the horizontal and vertical alignment policies for actor
inside layout
layout |
||
actor |
a ClutterActor child of |
|
x_align |
Horizontal alignment policy for |
|
y_align |
Vertical alignment policy for |
Since 1.4
void clutter_table_layout_get_alignment (ClutterTableLayout *layout
,ClutterActor *actor
,ClutterTableAlignment *x_align
,ClutterTableAlignment *y_align
);
Retrieves the horizontal and vertical alignment policies for actor
as set using clutter_table_layout_pack()
or
clutter_table_layout_set_alignment()
.
layout |
||
actor |
a ClutterActor child of |
|
x_align |
return location for the horizontal alignment policy. |
[out] |
y_align |
return location for the vertical alignment policy. |
[out] |
Since 1.4
void clutter_table_layout_set_expand (ClutterTableLayout *layout
,ClutterActor *actor
,gboolean x_expand
,gboolean y_expand
);
Sets the horizontal and vertical expand policies for actor
inside layout
layout |
||
actor |
a ClutterActor child of |
|
x_expand |
whether |
|
y_expand |
whether |
Since 1.4
void clutter_table_layout_get_expand (ClutterTableLayout *layout
,ClutterActor *actor
,gboolean *x_expand
,gboolean *y_expand
);
Retrieves the horizontal and vertical expand policies for actor
as set using clutter_table_layout_pack()
or clutter_table_layout_set_expand()
layout |
||
actor |
a ClutterActor child of |
|
x_expand |
return location for the horizontal expand policy. |
[out] |
y_expand |
return location for the vertical expand policy. |
[out] |
Since 1.4
void clutter_table_layout_set_fill (ClutterTableLayout *layout
,ClutterActor *actor
,gboolean x_fill
,gboolean y_fill
);
Sets the horizontal and vertical fill policies for actor
inside layout
layout |
||
actor |
a ClutterActor child of |
|
x_fill |
whether |
|
y_fill |
whether |
Since 1.4
void clutter_table_layout_get_fill (ClutterTableLayout *layout
,ClutterActor *actor
,gboolean *x_fill
,gboolean *y_fill
);
Retrieves the horizontal and vertical fill policies for actor
as set using clutter_table_layout_pack()
or clutter_table_layout_set_fill()
layout |
||
actor |
a ClutterActor child of |
|
x_fill |
return location for the horizontal fill policy. |
[out] |
y_fill |
return location for the vertical fill policy. |
[out] |
Since 1.4
void clutter_table_layout_get_span (ClutterTableLayout *layout
,ClutterActor *actor
,gint *column_span
,gint *row_span
);
Retrieves the row and column span for actor
as set using
clutter_table_layout_pack()
or clutter_table_layout_set_span()
layout |
||
actor |
a ClutterActor child of |
|
column_span |
return location for the col span. |
[out] |
row_span |
return location for the row span. |
[out] |
Since 1.4
void clutter_table_layout_set_span (ClutterTableLayout *layout
,ClutterActor *actor
,gint column_span
,gint row_span
);
Sets the row and column span for actor
inside layout
layout |
||
actor |
a ClutterActor child of |
|
column_span |
Column span for |
|
row_span |
Row span for |
Since 1.4
void clutter_table_layout_set_use_animations (ClutterTableLayout *layout
,gboolean animate
);
Sets whether layout
should animate changes in the layout properties
The duration of the animations is controlled by
clutter_table_layout_set_easing_duration()
; the easing mode to be used
by the animations is controlled by clutter_table_layout_set_easing_mode()
Since 1.4
gboolean
clutter_table_layout_get_use_animations
(ClutterTableLayout *layout
);
Retrieves whether layout
should animate changes in the layout properties
Since clutter_table_layout_set_use_animations()
Since 1.4
void clutter_table_layout_set_easing_duration (ClutterTableLayout *layout
,guint msecs
);
Sets the duration of the animations used by layout
when animating changes
in the layout properties
Use clutter_table_layout_set_use_animations()
to enable and disable the
animations
Since 1.4
guint
clutter_table_layout_get_easing_duration
(ClutterTableLayout *layout
);
Retrieves the duration set using clutter_table_layout_set_easing_duration()
Since 1.4
void clutter_table_layout_set_easing_mode (ClutterTableLayout *layout
,gulong mode
);
Sets the easing mode to be used by layout
when animating changes in layout
properties
Use clutter_table_layout_set_use_animations()
to enable and disable the
animations
layout |
||
mode |
an easing mode, either from ClutterAnimationMode or a logical id
from |
Since 1.4
gulong
clutter_table_layout_get_easing_mode (ClutterTableLayout *layout
);
Retrieves the easing mode set using clutter_table_layout_set_easing_mode()
Since 1.4
The alignment policies available on each axis of the ClutterTableLayout
Align the child to the top or to the left of a cell in the table, depending on the axis |
||
Align the child to the center of a cell in the table |
||
Align the child to the bottom or to the right of a cell in the table, depending on the axis |
Since 1.4
struct ClutterTableLayout;
The ClutterTableLayout structure contains only private data and should be accessed using the provided API
Since 1.4
struct ClutterTableLayoutClass { };
The ClutterTableLayoutClass structure contains only private data and should be accessed using the provided API
Since 1.4
“column-spacing”
property “column-spacing” guint
The spacing between columns of the ClutterTableLayout, in pixels
Flags: Read / Write
Default value: 0
Since 1.4
“easing-duration”
property “easing-duration” guint
The duration of the animations, in case “use-animations”
is set to TRUE
The duration is expressed in milliseconds
Flags: Read / Write
Default value: 500
Since 1.4
“easing-mode”
property “easing-mode” gulong
The easing mode for the animations, in case
“use-animations” is set to TRUE
The easing mode has the same semantics of “mode”: it can
either be a value from the ClutterAnimationMode enumeration, like
CLUTTER_EASE_OUT_CUBIC
, or a logical id as returned by
clutter_alpha_register_func()
The default value is CLUTTER_EASE_OUT_CUBIC
Flags: Read / Write
Since 1.4
“row-spacing”
property “row-spacing” guint
The spacing between rows of the ClutterTableLayout, in pixels
Flags: Read / Write
Default value: 0
Since 1.4
“use-animations”
property “use-animations” gboolean
Whether the ClutterTableLayout should animate changes in the layout properties
Flags: Read / Write
Default value: FALSE
Since 1.4