gjs@k.cs.cmu.edu (Gregory Stein) (07/30/86)
(try and eat me, line-eater) I am trying to create a region composed of the area of two adjoining rectangles. Whenever I create the region and then fill it, I only get something similar to two framerects, rather than two painted rects. I've tried using OpenRgn and then calls to FrameRect, and I've also tried using SetRectRgn and Unioning them together. Neither seems to work. Can anyone offer any suggestions? Greg gjs@k.cs.cmu.edu
dubois@uwmacc.UUCP (Paul DuBois) (08/01/86)
> I am trying to create a region composed of the area of two adjoining > rectangles. Whenever I create the region and then fill it, I only > get something similar to two framerects, rather than two painted rects. > I've tried using OpenRgn and then calls to FrameRect, and I've also > tried using SetRectRgn and Unioning them together. Neither seems to > work. Can anyone offer any suggestions? Here's a program that works. I assume you have a passing familiarity with Rascal (hee, hee, hee). Program Rgn; Uses __QuickDraw (*$U+*) uQuickDraw ; Link __QuickDraw : ; Proc _Init (); Var rgn: RgnHandle; r1, r2: Rect; { rgn := NewRgn (); OpenRgn (); SetRect (r1, 10, 10, 100, 100); SetRect (r2, 110, 110, 200, 200); FrameRect (r1); FrameRect (r2); CloseRgn (rgn); FillRgn (rgn, _Black ()); DisposeRgn (rgn); }; -- Paul DuBois UUCP: {allegra,ihnp4,seismo}!uwvax!uwmacc!dubois | ARPA: dubois@easter --+-- | Begin at my sanctuary... | Ezekiel 9:6