Re: why does print block in Lion?
Re: why does print block in Lion?
- Subject: Re: why does print block in Lion?
- From: Michael Babin <email@hidden>
- Date: Sat, 17 Sep 2011 10:16:01 -0500
On Sep 17, 2011, at 8:02 AM, Gerriet M. Denkmann wrote:
>
> See comments below:
>
>>
>> In my TestDocument (subclass of NSDocument) I added the following code (see comments inside, which explain what's happening when I do File â∫‚ Print...):
>>
>>
>> - (NSPrintOperation *)printOperationWithSettings:(NSDictionary *)printSettings error:(NSError **)outError
>> {
>
> When I remove the call above (runModalPrintOperation...) then it prints ok.
> The documentation says: "Overrides of printShowingPrintPanel: can invoke this method."
>
> Is this a documentation error, and it should be: "Overrides of printShowingPrintPanel: prior to Lion can invoke this method. In Lion it should NOT be used." ?
>
> Or am I just confused?
Perhaps I am pointing out the obvious, but you aren't overriding printShowingPrintPanel:, you are overriding printOperationWithSettings:error:. The documentation may be literally correct as is.
I'm not all that familiar with the ins and outs of this particular subset of NSDocument's methods, but is there a reason you wouldn't just return the NSPrintOperation you created from this method and let the caller (presumably printDocumentWithSettings: showPrintPanel: delegate: didPrintSelector: contextInfo:) handle the rest?
_______________________________________________
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