Re: Printing a layer-backed view
Re: Printing a layer-backed view
- Subject: Re: Printing a layer-backed view
- From: "Timothy J. Wood" <email@hidden>
- Date: Fri, 4 Jan 2008 14:31:18 -0800
On Jan 4, 2008, at 9:56 AM, Troy Stephens wrote:
Sorry to say there is indeed a bug that causes the views' drawing
to be redirected to their backing layers, even though the views are
being asked to draw for the purpose of printing.
Thanks for the confirmation.
Ways this can be worked around:
(1) temporarily switch off layer-backing of the view (or view
hierarchy) during printing, or
When doing this, the content disappears off the on-screen view.
Comical, and fine for testing, but not for release =)
(2) print from an identically configured offscreen view (or
hierarchy) that isn't layer-backed, or
This would sort of work, but I don't really want to have to set up
my views both ways if I can avoid it. I'm just exploring right now,
but the view I'm wanting to make layer backed is pretty complicated
and having two setup paths would be bad. On the flip side, while
printing, I'm unlikely to have any CIFilters in effect and all my
layers should be able to draw themselves via the CGContextRef path.
In this case, I'd need to be able to render the layer tree into the
CGContextRef as actual vector output.
Hopefully this will work once this bug is fixed. It'd be a bummer
to have to traverse the layer tree myself, applying transforms and
calling the CGContextRef methods, but it seems like I could do that if
I had to.
Thanks!
-tim
_______________________________________________
Cocoa-dev mailing list (email@hidden)
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:
This email sent to email@hidden