Important: The information in this document is obsolete and should not be used for new development.
Drawing Regions
After defining a region by using theNewRgn
function andOpenRgn
procedure, a number of drawing procedures, and theCloseRgn
procedure, you can draw the region's outline with theFrameRgn
procedure. You can draw its interior with thePaintRgn
andFillRgn
procedures. You can erase it by using theEraseRgn
procedure, and you can use theInvertRgn
procedure to reverse the colors of the pixels within it. In all of these procedures, you refer to a region by the handle returned by theNewRgn
function when you first created the region.These routines depend on the local coordinate system of the current graphics port. If you draw a region in a graphics port different from the one in which you defined the region, it may not appear in the proper position in the graphics port.
- WARNING
- If any horizontal or vertical line drawn through the region would intersect the region's outline more than 50 times, the results of these graphics operations are undefined. The
FrameRgn
procedure in particular requires that there would be no more than 25 such intersections.
Subtopics
- FrameRgn
- PaintRgn
- FillRgn
- EraseRgn
- InvertRgn