Name
NSPrintPanel — Mac OS X 10.0
Synopsis
This class provides the Mac OS X Print panel interface for Cocoa
applications. To obtain an instance of
NSPrintPanel
, use the class method
printPanel
. The panel is displayed and run when
the runModal
method is invoked, which will display
the print panel as a window. It is also possible to display the print
panel as a sheet attached to the document window; this is done with
the method beginSheetWithPrintInfo:modalFor-Window: delegate:didEndSelector:contextInfo
:.
Cocoa allows you to attach an accessory view to the print panel,
providing an interface for users to configure options related to how
your application handles printing. To set the accessory view, use the
method setAccessoryView
:.
|
@interface NSPrintPanel : NSObject
|
// Accessor Methods
|
- (void)setAccessoryView:(NSView *)aView; |
- (NSView *)accessoryView;
|
- (void)setJobStyleHint:(NSString *)hint; |
- (NSString *)jobStyleHint;
|
// Class Methods
|
+ (NSPrintPanel *)printPanel;
|
// Instance Methods
|
- (void)beginSheetWithPrintInfo:(NSPrintInfo *)printInfo modalForWindow:(NSWindow *)docWindow delegate:(id)delegate didEndSelector:(SEL)didEndSelector contextInfo:(void *)contextInfo; |
- (void)finalWritePrintInfo;
|
- (void)pickedAllPages:(id)sender; |
- (void)pickedButton:(id)sender; |
- (void)pickedLayoutList:(id)sender; |
- (int)runModal;
|
- (void)updateFromPrintInfo;
|
Get Cocoa in a Nutshell now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.