Important: The information in this document is obsolete and should not be used for new development.
DrawControls
Although you should generally use theUpdateControls
procedure to update controls in a window, you can instead use theDrawControls
procedure.
PROCEDURE DrawControls (theWindow: WindowPtr);
theWindow
- A pointer to a window whose controls you want to display.
DESCRIPTION
TheDrawControls
procedure draws all controls currently visible in the specified window. The controls are drawn in reverse order of creation; thus, in case of overlapping controls, the control created first appears frontmost in the window.Because the
UpdateControls
procedure redraws only those controls that need updating, your application should generally use it instead ofDrawControls
upon receiving an update event for a window that contains controls.You should call either
DrawControls
orUpdateControls
after calling the Window Manager procedureBeginUpdate
and before callingEndUpdate
.SPECIAL CONSIDERATIONS
The Dialog Manager automatically draws and updates controls in alert boxes and
dialog boxes.Window Manager routines such as
SelectWindow
,ShowWindow
, andBringToFront
do not automatically update the window's controls. They just add the appropriate regions to the window's update region, generating an update event.SEE ALSO
See the chapter "Dialog Manager" in this book for more information about including controls in alert boxes and dialog boxes. See the chapter "Window Manager" in this book for more information about Window Manager routines.