Thanks John, the second approach seems like it makes the most sense for my needs. cheers.

On 6 Apr 2009, at 19:10, John Calhoun wrote:

On Apr 6, 2009, at 6:31 AM, Memo Akten wrote:
Hi, I would like to add a PDFView to another view. But if my root view is layer backed I see nothing (just white).

The PDFView contains a subview. You can get to it via: -[PDFView documentView]. Perhaps retain this subview, remove from super, and add the subview to a layer backed view. I can think of a number of ways this may fail though (haven't tried it), so don't get your hopes up.....

If you simply want to display a single page though, just create your own NSView subclass and call PDFPage's draw method in your views drawRect method. You can set the needed scale on the current graphics context to have the PDFPage draw at the correct size.

Also, don't forget to erase to white before calling PDFPage's draw.

John Calhoun—_______________________________________________

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/memo%40memo.tv

This email sent to m...@memo.tv

_______________________________________________

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 arch...@mail-archive.com

Reply via email to