PrintOperationPropertyName
public enum PrintOperationPropertyName : String, PropertyNameProtocol
Undocumented
-
Determines whether the print operation may run asynchronously or not.
Some systems don’t support asynchronous printing, but those that do will return
GTK_PRINT_OPERATION_RESULT_IN_PROGRESS
as the status, and emit theGtkPrintOperation::done
signal when the operation is actually done.The Windows port does not support asynchronous operation at all (this is unlikely to change). On other platforms, all actions except for
GTK_PRINT_OPERATION_ACTION_EXPORT
support asynchronous operation.Declaration
Swift
case allowAsync = "allow-async"
-
The current page in the document.
If this is set before
gtk_print_operation_run()
, the user will be able to select to print only the current page.Note that this only makes sense for pre-paginated documents.
Declaration
Swift
case currentPage = "current-page"
-
Used as the label of the tab containing custom widgets. Note that this property may be ignored on some platforms.
If this is
nil
, GTK+ uses a default label.Declaration
Swift
case customTabLabel = "custom-tab-label"
-
The
GtkPageSetup
used by default.This page setup will be used by
gtk_print_operation_run()
, but it can be overridden on a per-page basis by connecting to theGtkPrintOperation::request-page-setup
signal.Declaration
Swift
case defaultPageSetup = "default-page-setup"
-
If
true
, page size combo box and orientation combo box are embedded into page setup page.Declaration
Swift
case embedPageSetup = "embed-page-setup"
-
The name of a file to generate instead of showing the print dialog. Currently, PDF is the only supported format.
The intended use of this property is for implementing “Export to PDF” actions.
“Print to PDF” support is independent of this and is done by letting the user pick the “Print to PDF” item from the list of printers in the print dialog.
Declaration
Swift
case exportFilename = "export-filename"
-
Determines whether there is a selection in your application. This can allow your application to print the selection. This is typically used to make a “Selection” button sensitive.
Declaration
Swift
case hasSelection = "has-selection"
-
A string used to identify the job (e.g. in monitoring applications like eggcups).
If you don’t set a job name, GTK+ picks a default one by numbering successive print jobs.
Declaration
Swift
case jobName = "job-name"
-
The number of pages in the document.
This must be set to a positive number before the rendering starts. It may be set in a
GtkPrintOperation::begin-print
signal hander.Note that the page numbers passed to the
GtkPrintOperation::request-page-setup
andGtkPrintOperation::draw-page
signals are 0-based, i.e. if the user chooses to print all pages, the lastdraw-page
signal will be for pagen_pages
- 1.Declaration
Swift
case nPages = "n-pages"
-
The number of pages that will be printed.
Note that this value is set during print preparation phase (
GTK_PRINT_STATUS_PREPARING
), so this value should never be get before the data generation phase (GTK_PRINT_STATUS_GENERATING_DATA
). You can connect to theGtkPrintOperation::status-changed
signal and callgtk_print_operation_get_n_pages_to_print()
when print status isGTK_PRINT_STATUS_GENERATING_DATA
. This is typically used to track the progress of print operation.Declaration
Swift
case nPagesToPrint = "n-pages-to-print"
-
The
GtkPrintSettings
used for initializing the dialog.Setting this property is typically used to re-establish print settings from a previous print operation, see
gtk_print_operation_run()
.Declaration
Swift
case printSettings = "print-settings"
-
Determines whether to show a progress dialog during the print operation.
Declaration
Swift
case showProgress = "show-progress"
-
The status of the print operation.
Declaration
Swift
case status = "status"
-
A string representation of the status of the print operation. The string is translated and suitable for displaying the print status e.g. in a
GtkStatusbar
.See the
GtkPrintOperation:status
property for a status value that is suitable for programmatic use.Declaration
Swift
case statusString = "status-string"
-
If
true
, the print operation will support print of selection. This allows the print dialog to show a “Selection” button.Declaration
Swift
case supportSelection = "support-selection"
-
If
true
, the print operation will try to continue report on the status of the print job in the printer queues and printer. This can allow your application to show things like “out of paper” issues, and when the print job actually reaches the printer. However, this is often implemented using polling, and should not be enabled unless needed.Declaration
Swift
case trackPrintStatus = "track-print-status"
-
The transformation for the cairo context obtained from
GtkPrintContext
is set up in such a way that distances are measured in units ofunit
.Declaration
Swift
case unit = "unit"
-
If
true
, the transformation for the cairo context obtained fromGtkPrintContext
puts the origin at the top left corner of the page (which may not be the top left corner of the sheet, depending on page orientation and the number of pages per sheet). Otherwise, the origin is at the top left corner of the imageable area (i.e. inside the margins).Declaration
Swift
case useFullPage = "use-full-page"