Legacy Documentclose button

Important: The information in this document is obsolete and should not be used for new development.

Previous Book Contents Book Index Next

Inside Macintosh: Imaging With QuickDraw /
Chapter 2 - Basic QuickDraw / Basic QuickDraw Reference
Routines / Managing Bitmaps, Port Rectangles, and Clipping Regions


ClipRect

To change the clipping region of the current graphics port (basic or color), use the ClipRect procedure.

PROCEDURE ClipRect (r: rect);
r
A rectangle to define the boundary of the new clipping region for the current graphics port.
DESCRIPTION
The ClipRect procedure changes the clipping region of the current graphics port to a region that's equivalent to the rectangle specified in the r parameter. ClipRect doesn't change the region handle, but it affects the clipping region itself. Since ClipRect makes a copy of the given rectangle, any subsequent changes you make to that rectangle do not affect the clipping region of the port.

SPECIAL CONSIDERATIONS
The ClipRect procedure may move or purge memory blocks in the application heap. Your application should not call this procedure at interrupt time.

SEE ALSO
Figure 2-4 on page 2-11 illustrates a clipping region that has been set to exclude the scroll bars of a window.


Previous Book Contents Book Index Next

© Apple Computer, Inc.
7 JUL 1996