All Manuals > CAPI User Guide and Reference Manual > 21 CAPI Reference Entries

NextPrevUpTopContentsIndex

x-y-adjustable-layout

Class
Summary

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).

Package

capi

Superclasses

layout

Subclasses

simple-layout
grid-layout

Initargs

:x-adjust

The adjust value for the x direction.

:y-adjust

The adjust value for the y direction.

Accessors

layout-x-adjust
layout-y-adjust

Description

The values x-adjust and y-adjust of the slots are used by layouts to decide what to do when a pane is smaller than the space in which it is being laid out. Typically the values will be a keyword or a list of the form ( keyword n ) where n is an integer. These values of adjust are interpreted as by pane-adjusted-position.

:top is the default for y-adjust and :left is the default for x-adjust .

Example

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)
                               )))))
 
(capi:apply-in-pane-process
 column #'(setf capi:layout-x-adjust) :right column)
 
(capi:apply-in-pane-process
 column #'(setf capi:layout-x-adjust) :center column)
See also

pane-adjusted-position

 


CAPI User Guide and Reference Manual (Unix version) - 25 Feb 2015

NextPrevUpTopContentsIndex