-------------- Original message ---------------------- From: glenn andreas <[EMAIL PROTECTED]> > > CG is "stateless", in that there is no "current context" (all drawing > to a CGContext requires passing the CGContextRef). NSGraphicsContext, > on the other hand, involves an implicit "current context". If you > change that, you need to change it back - that's what currentContext/ > setCurrentContext does. Just because NSGraphicsContext is built on > top of CGContextRef doesn't mean that they have the same semantics > (nor is NSGraphicsContext "just a wrapper" - it does a few more things). > Thanks Glenn.
I'm still confused as to exactly how I should restore or change the context "back to the original" since the original is a CGGraphicsContext. and the only NSGraphicsContext is one I create using the passed in CGGraphicsContext. It seems like a catch-22. I can't draw the text without creating an NSGraphicsContext and I can't restore a calling NSGraphicsContext because the calling context is a CGGraphics context which doesn't work with [NSGraphicsContext setCurrentContext: nsContext]; Any pointers? _______________________________________________ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please do not post admin requests or moderator comments to the list. Contact the moderators at cocoa-dev-admins(at)lists.apple.com Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com This email sent to [EMAIL PROTECTED]