Page 257 Table of Contents Index Page 259
Chapters
1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30
A, B, C, D, E



CHAPTER 25. MENU FACILITIES

that is used to compare cache values, which defaults to equal. Both cache-value and unique-id
have dynamic extent.

max-width and max-height specify the maximum width and height of the menu, in device units.
They can be overridden by n-rows and n-columns.

n-rows and n-columns specify the number of rows and columns in the menu.

x-spacing specifies the amount of space to be inserted between columns of the table; the default
is the width of a space character. It is specified the same way as the :x-spacing option to
formatting-table.

y-spacing specifies the amount of blank space inserted between rows of the table; the default is
the vertical spacing for the stream. The possible values for this option are the same as for the
:y-spacing option to formatting-table.

cell-align-x specifies the horizontal placement of the contents of the cell. Can be one of :left,
:right, or :center. The default is :left. The semantics are the same as for the :align-x
option to formatting-cell.

cell-align-y specifies the vertical placement of the contents of the cell. Can be one of :top,
:bottom, or :center. The default is :top. The semantics are the same as for the :align-y
option to formatting-cell.

pointer-documentation is either nil (the default), meaning that no pointer documentation should
be computed, or a stream on which pointer documentation should be displayed.

=> menu-choose-from-drawer menu type drawer &key x-position y-position cache unique-id id-test
cache-value cache-test default-presentation pointer-documentation
[Generic Function]
This is a a lower-level routine for displaying menus. It allows the programmer much more
flexibility in the menu layout. Unlike menu-choose, which automatically creates and lays out the
menu, menu-choose-from-drawer takes a programmer-provided window and drawing function.
The drawing function is responsible for drawing the contents of the menu; generally it will be a
lexical closure that closes over the menu items.

menu-choose-from-drawer draws the menu items into that window using the drawing function.
The drawing function gets called with two arguments, stream and type. It can use type for its
own purposes, such as using it as the type argument in a call to present.

menu-choose-from-drawer returns two values: the object the user clicked on, and the pointer
button event. If the user aborts out of the menu, a single value is returned, nil.

menu is a CLIM window to use for the menu. This argument may be specialized to provide a
different look-and-feel for different host window systems.

type is a presentation type specifier for each of the mouse-sensitive items in the menu. This is
the input context that will be established once the menu is displayed. For programmers who
don't need to define their own types, a useful presentation type is menu-item.


Page 257 Table of Contents Index Page 259
Chapters
1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30
A, B, C, D, E