Next Previous Up Top Contents Index

1 CAPI Reference Entries

contain

Function

Summary

Thecontain function creates a container for a CAPI element and is provided as a convenient way of testing CAPI functionality.
Syntax

contain element &key screen &allow-other-keys

Description

This displays a window containing element and returns element as its result. It is mainly used during interactive sessions as a convenient way of testing CAPI functionality, and many of the CAPI examples use it for this purpose. The container is created usingmake-container, which can make containers for any of the following classes:

simple-pane
layout
interface
pinboard-object
menu
menu-item
menu-component
list

In the case of alist, the CAPI tries to see what sort of objects they are and makes an appropriate container. For instance, if they were allsimple-panes it would put them into acolumn-layout.
Example

(capi:contain (make-instance 'capi:text-input-pane))
(capi:contain (make-instance
               'capi:column-layout
               :description '("Title:"
                              ,(make-instance
                                'capi:text-input-pane))))

(capi:contain (make-instance 'capi:menu-item :title "Test"))

See also

make-container
display
element

LispWorks CAPI Reference Manual - 17 Oct 1998

Next Previous Up Top Contents Index

Generated with Harlequin WebMaker