Printing an NSDocument

Posted by Brian Postow on Stack Overflow See other posts from Stack Overflow or by Brian Postow
Published on 2010-03-18T19:47:04Z Indexed on 2010/03/18 19:51 UTC
Read the original article Hit count: 456

I'm trying to print a document. The document is an array of NSImageReps, or a single NSPDFImageRep, which has multiple pages. I'm having trouble figuring out how to use the NSPrintOperation class to print this.

The NSPrintOperation seems to need an NSView to print. Do I need to manually add each image into the view at a calculated position and then let it do the pagination? that seems like it isn't in the spirit of Cocoa... is there some technique that I'm missing?

© Stack Overflow or respective owner

Related posts about cocoa

Related posts about objective-c