The class x-y-adjustable-layout
provides functionality for positioning panes in a space larger than themselves (for example, it is used to choose whether to center them, or left justify them).
The values for x-adjust
and y-adjust
are used by layouts to decide what to do when a pane is smaller than the space in which it is being laid out. The values are interpreted by the function pane-adjusted-offset.
These are the allowed values:
Place the pane at the top of the region. This is the default for y-adjust .
Place the pane at the bottom of the region.
Place the pane at the left of the region. This is the default for x-adjust .
Place the pane at the right of the region.
Place the pane in the center of the region.
Note: column-layout
is a subclass of x-y-adjustable-layout
.
(setq column (capi:contain
(make-instance
'capi:column-layout
:description (list
(make-instance
'capi:push-button
:text "Ok")
(make-instance
'capi:list-panel
:items '(1 2 3 4 5)
)))
:process nil))
(setf (capi:layout-x-adjust column) :right)
(setf (capi:layout-x-adjust column) :center)