PrintJob

open class PrintJob(pointer: <Error class: unknown class><<Error class: unknown class>>)

A GtkPrintJob object represents a job that is sent to a printer.

You only need to deal directly with print jobs if you use the non-portable class@Gtk.PrintUnixDialog API.

Use method@Gtk.PrintJob.get_surface to obtain the cairo surface onto which the pages must be drawn. Use method@Gtk.PrintJob.send to send the finished job to the printer. If you don’t use cairo GtkPrintJob also supports printing of manually generated PostScript, via method@Gtk.PrintJob.set_source_file.

Skipped during bindings generation

  • parameter n_ranges: n_ranges: Out parameter is not supported

  • method get_surface: Return type cairo.Surface is unsupported

  • parameter ranges: PageRange

  • method page-setup: Property has no getter nor setter

Constructors

Link copied to clipboard
constructor(title: String, printer: Printer, settings: PrintSettings, pageSetup: PageSetup)

Creates a new GtkPrintJob.

constructor(pointer: <Error class: unknown class><<Error class: unknown class>>)

Types

Link copied to clipboard
object Companion

Properties

Link copied to clipboard
val gtkPrintJobPointer: <Error class: unknown class><<Error class: unknown class>>
Link copied to clipboard
open val printer: Printer

The printer to send the job to.

Link copied to clipboard

Printer settings.

Link copied to clipboard
open val title: String

The title of the print job.

Link copied to clipboard

true if the print job will continue to emit status-changed signals after the print data has been setn to the printer.

Functions

Link copied to clipboard
fun connectStatusChanged(connectFlags: <Error class: unknown class> = ConnectFlags(0u), handler: () -> Unit): <Error class: unknown class>

Emitted when the status of a job changes.

Link copied to clipboard
open fun getCollate(): Boolean

Gets whether this job is printed collated.

Link copied to clipboard
open fun getNumCopies(): <Error class: unknown class>

Gets the number of copies of this job.

Link copied to clipboard
open fun getNUp(): <Error class: unknown class>

Gets the n-up setting for this job.

Link copied to clipboard

Gets the n-up layout setting for this job.

Link copied to clipboard
open fun getPages(): PrintPages

Gets the GtkPrintPages setting for this job.

Link copied to clipboard
open fun getPageSet(): PageSet

Gets the GtkPageSet setting for this job.

Link copied to clipboard
open fun getReverse(): Boolean

Gets whether this job is printed reversed.

Link copied to clipboard
open fun getRotate(): Boolean

Gets whether the job is printed rotated.

Link copied to clipboard
open fun getScale(): <Error class: unknown class>

Gets the scale for this job.

Link copied to clipboard

Gets the status of the print job.

Link copied to clipboard
open fun send(callback: PrintJobCompleteFunc)

Sends the print job off to the printer.

Link copied to clipboard
open fun setCollate(collate: Boolean)

Sets whether this job is printed collated.

Link copied to clipboard
open fun setNumCopies(numCopies: <Error class: unknown class>)

Sets the number of copies for this job.

Link copied to clipboard
open fun setNUp(nUp: <Error class: unknown class>)

Sets the n-up setting for this job.

Link copied to clipboard
open fun setNUpLayout(layout: NumberUpLayout)

Sets the n-up layout setting for this job.

Link copied to clipboard
open fun setPages(pages: PrintPages)

Sets the GtkPrintPages setting for this job.

Link copied to clipboard
open fun setPageSet(pageSet: PageSet)

Sets the GtkPageSet setting for this job.

Link copied to clipboard
open fun setReverse(reverse: Boolean)

Sets whether this job is printed reversed.

Link copied to clipboard
open fun setRotate(rotate: Boolean)

Sets whether this job is printed rotated.

Link copied to clipboard
open fun setScale(scale: <Error class: unknown class>)

Sets the scale for this job.

Link copied to clipboard
open fun setSourceFd(fd: <Error class: unknown class>): <Error class: unknown class><Boolean>

Make the GtkPrintJob send an existing document to the printing system.

Link copied to clipboard
open fun setSourceFile(filename: String): <Error class: unknown class><Boolean>

Make the GtkPrintJob send an existing document to the printing system.