type
=“grid”
layout
s
<dim id="no-padding">0</dim> <dim id="extra-padding">2.0</dim> <layout type="grid" id="main-window-grid"> <halign> <col>0</col> <halign>left</halign> </halign> <valign> <row>0</row> <valign>middle</valign> </valign> <padding> <row>0</row> <side>left</side> <padding>extra-padding</padding> </padding> </layout> <!-- in some factory... --> <container> <name>main-window-grid</name> <type>grid</type> <config> <row_padding>no-padding</row_padding> </config> </container> x::w::gridlayoutmanager glm=container->get_layoutmanager(); glm->generate("main-window-grid", generator, elements);
The contents of a
layout
s of
type
=“grid”
specify the methods invoked by grid
layout manager's generate
().
type
=“grid”
layout
s
A container
with a
type
=“grid”
creates a container that uses the
grid layout manager.
An optional
config
element sets non-default values
of the
x::w::new_gridlayoutmanager
that creates the container:
col_padding
Initializes
x::w::new_gridlayoutmanager
's
col_paddings
value:
<config> <col_padding>no-padding</col_padding> </config> <!-- ... --> <dim id="no-padding">0</dim>
The col_padding
element references a
dim
element in the theme file.
row_padding
Initializes
x::w::new_gridlayoutmanager
's
row_paddings
value:
<config> <row_padding>no-padding</row_padding> </config> <!-- ... --> <dim id="no-padding">0</dim>
The row_padding
element references a
dim
element in the theme file.
synchronized_columns
Initializes
x::w::new_gridlayoutmanager
's
synchronized_columns
object:
<config> <synchronized_columns>table_columns</synchronized_columns> </config>
All generate
()d grids
with the
same synchronized_columns
name
have the
same
x::w::synchronized_axis
handle.
The element's name is an opaque label.
x::w::synchronized_axis
objects
get automatically created, internally, and associated with
their name.