Groups | Search | Server Info | Login | Register
Groups > comp.lang.objective-c > #39
| From | "Alex Temple" <alextemple1@btinternet.com> |
|---|---|
| Newsgroups | comp.lang.objective-c |
| Subject | NSCompositeXOR and Bezier Paths |
| Date | 2012-01-05 23:47 +0000 |
| Message-ID | <mPydnWFblIELq5vSnZ2dnUVZ8vCdnZ2d@bt.com> (permalink) |
I'm trying to draw a rectangle from within a mouse event. This nearly works, but the rectangle is always black, irrespective of how the Compositing Operation is set. [self lockFocus]; [[NSColor blackColor] set]; [[NSGraphicsContext currentContext] setCompositingOperation: NSCompositeXOR]; // ignored?? [[NSBezierPath bezierPathWithRect: myRect] stroke]; [self unlockFocus]; [[NSCurrentGaphicsContext] flushGraphics]; // I found this was necessary Does the Compositing Operation have any effect on Beziers?
Back to comp.lang.objective-c | Previous | Next — Next in thread | Find similar
NSCompositeXOR and Bezier Paths "Alex Temple" <alextemple1@btinternet.com> - 2012-01-05 23:47 +0000 Re: NSCompositeXOR and Bezier Paths cb@mer.df.lth.se (Christian Brunschen) - 2012-01-06 10:45 +0000
csiph-web