On Aug 10, 2010, at 2:45 PM, Brian Postow wrote:
> I have a CGImageRef, and I need to put it into a PDFPage. At the moment, the 
> only way I see to do that is to turn it into an NSImage first.

That will work, but it is also possible to subclass PDFPage and override the 
-[drawWithBox:] method in your subclass. Your method would get the current 
context as a CGContext and draw the CGImageRef directly.

Make sure to return the correct size in -[PDFPage boundsForBox:] as well.

John Calhoun—_______________________________________________

Cocoa-dev mailing list ([email protected])

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]

Reply via email to