Instance Method

printDocument(_:)

Prints the receiver in response to the user choosing the Print menu command.

Declaration

@IBAction func printDocument(_ sender: Any?)

Parameters

sender

The control sending the message.

Discussion

An NSDocument object receives this action message as it travels up the responder chain. The default implementation invokes print(withSettings:showPrintPanel:delegate:didPrint:contextInfo:).

See Also

Handling User Actions

func runPageLayout(Any?)

The action method invoked in the receiver as first responder when the user chooses the Page Setup menu command.

func revertToSaved(Any?)

The action of the File menu item Revert in a document-based app.

func save(Any?)

The action method invoked in the receiver as first responder when the user chooses the Save menu command.

func saveAs(Any?)

The action method invoked in the receiver as first responder when the user chooses the Save As menu command.

func saveTo(Any?)

The action method invoked in the receiver as first responder when the user chooses the Save To menu command.