A reflowing layout manager
<clutter-flow-layout>
is a layout manager which implements the
following policy:
the preferred natural size depends on the value of the
<"orientation">
property; the layout will try to maintain all its
children on a single row or column;
if either the width or the height allocated are smaller than the preferred ones, the layout will wrap; in this case, the preferred height or width, respectively, will take into account the amount of columns and rows;
each line (either column or row) in reflowing will have the size of the
biggest cell on that line; if the <"homogeneous">
property is set
to ‘#f
’ the actor will be allocated within that area, and if
set to ‘#t
’ instead the actor will be given exactly that
area;
the size of the columns or rows can be controlled for both minimum and maximum; the spacing can also be controlled in both columns and rows.
(The missing figure, flow-layout-image
The image shows a <clutter-flow-layout>
with the
<"orientation">
propert set to ‘CLUTTER_FLOW_HORIZONTAL’.
<clutter-flow-layout>
is available since Clutter 1.2
<clutter-flow-orientation>
) ⇒ (ret <clutter-layout-manager>
)Creates a new
<clutter-flow-layout>
with the given orientation
- orientation
- the orientation of the flow layout
- ret
- the newly created
<clutter-flow-layout>
Since 1.2
<clutter-flow-layout>
) (homogeneous bool
)Sets whether the layout should allocate the same space for each child
- layout
- a
<clutter-flow-layout>
- homogeneous
- whether the layout should be homogeneous or not
Since 1.2
<clutter-flow-layout>
) ⇒ (ret bool
)Retrieves whether the layout is homogeneous
- layout
- a
<clutter-flow-layout>
- ret
- ‘
#t
’ if the<clutter-flow-layout>
is homogeneousSince 1.2
<clutter-flow-layout>
) (orientation <clutter-flow-orientation>
)Sets the orientation of the flow layout
The orientation controls the direction used to allocate the children: either horizontally or vertically. The orientation also controls the direction of the overflowing
- layout
- a
<clutter-flow-layout>
- orientation
- the orientation of the layout
Since 1.2
<clutter-flow-layout>
) (spacing float
)Sets the spacing between rows, in pixels
- layout
- a
<clutter-flow-layout>
- spacing
- the space between rows
Since 1.2
<clutter-flow-layout>
) ⇒ (ret float
)Retrieves the spacing between rows
- layout
- a
<clutter-flow-layout>
- ret
- the spacing between rows of the
<clutter-flow-layout>
, in pixelsSince 1.2
<clutter-flow-layout>
) (min_height float
) (max_height float
)Sets the minimum and maximum heights that a row can have
- layout
- a
<clutter-flow-layout>
- min-height
- the minimum height of a row
- max-height
- the maximum height of a row
Since 1.2
<clutter-flow-layout>
) ⇒ (min_height float
) (max_height float
)Retrieves the minimum and maximum row heights
- layout
- a
<clutter-flow-layout>
- min-height
- return location for the minimum row height, or ‘
#f
’.- max-height
- return location for the maximum row height, or ‘
#f
’.Since 1.2