Arguments: name &rest arguments&key (class 'dialog) (owner (development-main-window *system*)) dialog-items form-p child-name behind state &allow-other-keys
Creates and returns a new window. The name argument should be a symbol (we recommend using keywords) which does not name any other object. The name can be passed as an argument to find-window and other find- functions to get a programmatic handle on a window.
When using the Integrated Development Environment, you can design
windows to be used in your application using forms. A form
is a class of
window that is used to design windows of other classes. The Integrated
Development Environment creates a function from a form you have
designed which creates to designed window. Get a new form by clicking
File |
New Form. You are asked for the class of the window (the
value of the :device argument) and that is the type of window that
will be designed with the form.
Here are some keyword arguments to make-window:
dialog
. The class of the window
being created. The standard choices besides dialog
are text-edit-window
, bitmap-window
, frame-window
, and
non-refreshing-window
. We recommend
that you subclass these standard classes so your customizations will
not affect existing windows. In earlier releases, this argument was
named device and that name is still accepted. Do
not, of course, specify both.
The accessor/setter of the class
property is device, though it is
uncommon to need to use that function programmatically (one typically
sets this slot upon creation or using the class
slot in an inspector window). (class-name (class-of
object))
also serves as an accessor.
nil
. The value should be a list of controls (also
called widgets, whence the former argument name) to be placed on the
window. While controls can be placed on any window, only windows of
type dialog-mixin
(that is, only windows
whose class is a subclass of dialog-mixin
) will have the special
Windows dialog behavior. In such windows, pressing the TAB key moves
the keyboard focus from one control to another and pressing
Alt-[letter] will move the keyboard focus to the control that
has the letter underlined as its access character. (For example,
pressing Alt-A will move keyboard focus to the control whose access
letter is an underlined A.)
A control object can only be used on one window.
The use of :widgets to name this argument is deprecated. :dialog-items should be used instead. :widgets is accepted and both should not be specified.
nil
. (Note: in
releases prior to 6.0, default was t when :widgets (now :dialog-items)
was true.) See pop-up. This argument should be
specified true if the window is intended to be
modal. Note that the value of this property
cannot be changed once the window has been created.
nil
. If true, create
a form (an instance of the form
class) rather than an instance
of the class specified to :device. That form can be used to design the
window. As part of the design, a function to create the window
associated with the form is written.
frame-with-single-child
mixin (such
as non-refreshing-window
or bitmap-window
), the
:child-name argument may be passed to make-window to provide a name
for the child pane that is created automatically for the frame
window. As with other object names that are used in Allegro CL for
finding objects, the name should be a symbol.
In fact it is unlikely that this name will be needed programmatically, since the child-pane can be found by calling frame-child on the parent frame window, it is nevertheless often helpful for arbitrary objects to have names so that the they can be recognized more easily during debugging.
nil
, which places the
window in front or its siblings. A value of t
places the window behind all of its siblings. If the value is another
window that is already on the owner window, the new window is placed
immediately behind the specified window.
When creating a window, the window is placed into its initial visible state (as specified by the :state initarg) by a device-open :around method. This means that if an application adds device-open methods (including :after methods) for its window subclasses, for example to set up child windows on the window, the main window will be shown only after this setup is complete, to avoid distracting the user and to increase creation speed. (An alternate approach is simply to create the main window in :shrunk state, then do arbitrary setup, and then set the state of the main window to :normal.)
There are many other options (specified by initarg – a keyword – value pairs) to make-window. In general, the initargs are keywords with the same name as properties, :left-attachment for left-attachment, e.g.)
Common Graphics and IDE documentation is described in About Common Graphics and IDE documentation in cgide.htm.
The documentation is described in introduction.htm and the index is in index.htm.
Copyright (c) 1998-2000, Franz Inc. Berkeley, CA., USA. All rights reserved.
Created 2000.10.5.