AlignWindow
TheAlignWindowfunction moves a specified window to the nearest optimal alignment position.
pascal void AlignWindow (WindowPtr wp, Boolean front, const Rect *alignmentRect, AlignmentProcRecordPtr alignmentProc);
wp- Points to the window to be aligned.
front- Specifies the frontmost window. If the front parameter is
trueand the window specified in thewpparameter isn't the active window,AlignWindowmakes it the active window by calling the Window Manager'sSelectWindowroutine.alignmentRect- Contains a pointer to a rectangle in window coordinates that allows you to align the window to a rectangle within the window. Set this
parameter tonilto align using the bounds of the window.alignmentProc- Points to a function that allows you to provide your own alignment behavior. Set this parameter to
nilto use the standard behavior. Your alignment function must be in the following form:pascal void MyAlignmentProc(Rect *rp, long refcon);
See "Alignment Functions" on page 3-149 for details.SEE ALSO
TheAlignWindowfunction is similar to the Window Manager'sMoveWindowroutine. See Inside Macintosh: Macintosh ToolBox Essentials Essentials for details.