### Class

# Gtk Printer

since: 4.0

#### Description [src]

    final class Gtk.Printer : GObject.Object
    {
      /* No available fields */
    }

A `GtkPrinter` object represents a printer.

You only need to deal directly with printers if you use the non-portable `GtkPrintUnixDialog` API.

A `GtkPrinter` allows to get status information about the printer, such as its description, its location, the number of queued jobs, etc. Most importantly, a `GtkPrinter` object can be used to create a `GtkPrintJob` object, which lets you print to the printer.

Available since: 4.0

#### Ancestors

- GObject

#### Constructors

###### gtk_printer_new

Creates a new `GtkPrinter`.

since: 4.0

#### Instance methods

###### gtk_printer_accepts_pdf

Returns whether the printer accepts input in PDF format.

since: 4.0

###### gtk_printer_accepts_ps

Returns whether the printer accepts input in PostScript format.

since: 4.0

###### gtk_printer_compare

Compares two printers.

since: 4.0

###### gtk_printer_get_backend

Returns the backend of the printer.

since: 4.0

###### gtk_printer_get_capabilities

Returns the printer’s capabilities.

since: 4.0

###### gtk_printer_get_default_page_size

Returns default page size of `printer`.

since: 4.0

###### gtk_printer_get_description

Gets the description of the printer.

since: 4.0

###### gtk_printer_get_hard_margins

Retrieve the hard margins of `printer`.

since: 4.0

###### gtk_printer_get_hard_margins_for_paper_size

Retrieve the hard margins of `printer` for `paper_size`.

since: 4.0

###### gtk_printer_get_icon_name

Gets the name of the icon to use for the printer.

since: 4.0

###### gtk_printer_get_job_count

Gets the number of jobs currently queued on the printer.

since: 4.0

###### gtk_printer_get_location

Returns a description of the location of the printer.

since: 4.0

###### gtk_printer_get_name

Returns the name of the printer.

since: 4.0

###### gtk_printer_get_state_message

Returns the state message describing the current state of the printer.

since: 4.0

###### gtk_printer_has_details

Returns whether the printer details are available.

since: 4.0

###### gtk_printer_is_accepting_jobs

Returns whether the printer is accepting jobs.

since: 4.0

###### gtk_printer_is_active

Returns whether the printer is currently active (i.e. accepts new jobs).

since: 4.0

###### gtk_printer_is_default

Returns whether the printer is the default printer.

since: 4.0

###### gtk_printer_is_paused

Returns whether the printer is currently paused.

since: 4.0

###### gtk_printer_is_virtual

Returns whether the printer is virtual (i.e. does not represent actual printer hardware, but something like a CUPS class).

since: 4.0

###### gtk_printer_list_papers

Lists all the paper sizes `printer` supports.

since: 4.0

###### gtk_printer_request_details

Requests the printer details.

since: 4.0

##### Methods inherited from GObject (43)

Please see GObject for a full list of methods.

#### Properties

###### Gtk.Printer:accepting-jobs

`TRUE` if the printer is accepting jobs.

since: 4.0

###### Gtk.Printer:accepts-pdf

`TRUE` if this printer can accept PDF.

since: 4.0

###### Gtk.Printer:accepts-ps

`TRUE` if this printer can accept PostScript.

since: 4.0

###### Gtk.Printer:backend

The backend for the printer.

since: 4.0

###### Gtk.Printer:icon-name

Icon name to use for the printer.

since: 4.0

###### Gtk.Printer:is-virtual

`FALSE` if this represents a real hardware device.

since: 4.0

###### Gtk.Printer:job-count

Number of jobs queued in the printer.

since: 4.0

###### Gtk.Printer:location

Information about the location of the printer.

since: 4.0

###### Gtk.Printer:name

The name of the printer.

since: 4.0

###### Gtk.Printer:paused

`TRUE` if this printer is paused.

since: 4.0

###### Gtk.Printer:state-message

String giving the current status of the printer.

since: 4.0

#### Signals

###### Gtk.Printer::details-acquired

Emitted in response to a request for detailed information about a printer from the print backend.

since: 4.0

##### Signals inherited from GObject (1)

###### GObject::notify

The notify signal is emitted on an object when one of its properties has its value set through g_object_set_property(), g_object_set(), et al.

since: 2.0