PrinterProtocol

public protocol PrinterProtocol : ObjectProtocol

A GtkPrinter object represents a printer.

You only need to deal directly with printers if you use the non-portable [classGtk.PrintUnixDialog] 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 [classGtk.PrintJob] object, which lets you print to the printer.

The PrinterProtocol protocol exposes the methods and properties of an underlying GtkPrinter instance. The default implementation of these can be found in the protocol extension below. For a concrete class that implements these methods and properties, see Printer. Alternatively, use PrinterRef as a lighweight, unowned reference if you already have an instance you just want to use.

  • ptr

    Untyped pointer to the underlying GtkPrinter instance.

    Declaration

    Swift

    var ptr: UnsafeMutableRawPointer! { get }
  • printer_ptr Default implementation

    Typed pointer to the underlying GtkPrinter instance.

    Default Implementation

    Return the stored, untyped pointer as a typed pointer to the GtkPrinter instance.

    Declaration

    Swift

    var printer_ptr: UnsafeMutablePointer<GtkPrinter>! { get }
  • Required Initialiser for types conforming to PrinterProtocol

    Declaration

    Swift

    init(raw: UnsafeMutableRawPointer)

Printer Class

  • Bind a PrinterPropertyName source property to a given target object.

    Declaration

    Swift

    @discardableResult
    @inlinable
    func bind<Q, T>(property source_property: PrinterPropertyName, to target: T, _ target_property: Q, flags f: BindingFlags = .default, transformFrom transform_from: @escaping GLibObject.ValueTransformer = { $0.transform(destValue: $1) }, transformTo transform_to: @escaping GLibObject.ValueTransformer = { $0.transform(destValue: $1) }) -> BindingRef! where Q : PropertyNameProtocol, T : ObjectProtocol

    Parameters

    source_property

    the source property to bind

    target

    the target object to bind to

    target_property

    the target property to bind to

    flags

    the flags to pass to the Binding

    transform_from

    ValueTransformer to use for forward transformation

    transform_to

    ValueTransformer to use for backwards transformation

    Return Value

    binding reference or nil in case of an error

  • get(property:) Extension method

    Get the value of a Printer property

    Declaration

    Swift

    @inlinable
    func get(property: PrinterPropertyName) -> GLibObject.Value

    Parameters

    property

    the property to get the value for

    Return Value

    the value of the named property

  • set(property:value:) Extension method

    Set the value of a Printer property. Note that this will only have an effect on properties that are writable and not construct-only!

    Declaration

    Swift

    @inlinable
    func set(property: PrinterPropertyName, value v: GLibObject.Value)

    Parameters

    property

    the property to get the value for

    Return Value

    the value of the named property

Printer signals

  • Connect a Swift signal handler to the given, typed PrinterSignalName signal

    Declaration

    Swift

    @discardableResult
    @inlinable
    func connect(signal s: PrinterSignalName, flags f: ConnectFlags = ConnectFlags(0), handler h: @escaping SignalHandler) -> Int

    Parameters

    signal

    The signal to connect

    flags

    The connection flags to use

    data

    A pointer to user data to provide to the callback

    destroyData

    A GClosureNotify C function to destroy the data pointed to by userData

    handler

    The Swift signal handler (function or callback) to invoke on the given signal

    Return Value

    The signal handler ID (always greater than 0 for successful connections)

  • Connect a C signal handler to the given, typed PrinterSignalName signal

    Declaration

    Swift

    @discardableResult
    @inlinable
    func connect(signal s: PrinterSignalName, flags f: ConnectFlags = ConnectFlags(0), data userData: gpointer!, destroyData destructor: GClosureNotify? = nil, signalHandler h: @escaping GCallback) -> Int

    Parameters

    signal

    The signal to connect

    flags

    The connection flags to use

    data

    A pointer to user data to provide to the callback

    destroyData

    A GClosureNotify C function to destroy the data pointed to by userData

    signalHandler

    The C function to be called on the given signal

    Return Value

    The signal handler ID (always greater than 0 for successful connections)

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

    The success parameter indicates if the information was actually obtained.

    Note

    This represents the underlying details-acquired signal

    Declaration

    Swift

    @discardableResult
    @inlinable
    func onDetailsAcquired(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: PrinterRef, _ success: Bool) -> Void) -> Int

    Parameters

    flags

    Flags

    unownedSelf

    Reference to instance of self

    success

    true if the details were successfully acquired

    handler

    The signal handler to call Run the given callback whenever the detailsAcquired signal is emitted

  • detailsAcquiredSignal Extension method

    Typed details-acquired signal for using the connect(signal:) methods

    Declaration

    Swift

    static var detailsAcquiredSignal: PrinterSignalName { get }
  • 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.

    Note that getting this signal doesn’t itself guarantee that the value of the property has actually changed. When it is emitted is determined by the derived GObject class. If the implementor did not create the property with G_PARAM_EXPLICIT_NOTIFY, then any call to g_object_set_property() results in notify being emitted, even if the new value is the same as the old. If they did pass G_PARAM_EXPLICIT_NOTIFY, then this signal is emitted only when they explicitly call g_object_notify() or g_object_notify_by_pspec(), and common practice is to do that only when the value has actually changed.

    This signal is typically used to obtain change notification for a single property, by specifying the property name as a detail in the g_signal_connect() call, like this:

    (C Language Example):

    g_signal_connect (text_view->buffer, "notify::paste-target-list",
                      G_CALLBACK (gtk_text_view_target_list_notify),
                      text_view)
    

    It is important to note that you must use canonical parameter names as detail strings for the notify signal.

    Note

    This represents the underlying notify::accepting-jobs signal

    Declaration

    Swift

    @discardableResult
    @inlinable
    func onNotifyAcceptingJobs(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: PrinterRef, _ pspec: ParamSpecRef) -> Void) -> Int

    Parameters

    flags

    Flags

    unownedSelf

    Reference to instance of self

    pspec

    the GParamSpec of the property which changed.

    handler

    The signal handler to call Run the given callback whenever the notifyAcceptingJobs signal is emitted

  • notifyAcceptingJobsSignal Extension method

    Typed notify::accepting-jobs signal for using the connect(signal:) methods

    Declaration

    Swift

    static var notifyAcceptingJobsSignal: PrinterSignalName { get }
  • 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.

    Note that getting this signal doesn’t itself guarantee that the value of the property has actually changed. When it is emitted is determined by the derived GObject class. If the implementor did not create the property with G_PARAM_EXPLICIT_NOTIFY, then any call to g_object_set_property() results in notify being emitted, even if the new value is the same as the old. If they did pass G_PARAM_EXPLICIT_NOTIFY, then this signal is emitted only when they explicitly call g_object_notify() or g_object_notify_by_pspec(), and common practice is to do that only when the value has actually changed.

    This signal is typically used to obtain change notification for a single property, by specifying the property name as a detail in the g_signal_connect() call, like this:

    (C Language Example):

    g_signal_connect (text_view->buffer, "notify::paste-target-list",
                      G_CALLBACK (gtk_text_view_target_list_notify),
                      text_view)
    

    It is important to note that you must use canonical parameter names as detail strings for the notify signal.

    Note

    This represents the underlying notify::accepts-pdf signal

    Declaration

    Swift

    @discardableResult
    @inlinable
    func onNotifyAcceptsPdf(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: PrinterRef, _ pspec: ParamSpecRef) -> Void) -> Int

    Parameters

    flags

    Flags

    unownedSelf

    Reference to instance of self

    pspec

    the GParamSpec of the property which changed.

    handler

    The signal handler to call Run the given callback whenever the notifyAcceptsPdf signal is emitted

  • notifyAcceptsPdfSignal Extension method

    Typed notify::accepts-pdf signal for using the connect(signal:) methods

    Declaration

    Swift

    static var notifyAcceptsPdfSignal: PrinterSignalName { get }
  • 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.

    Note that getting this signal doesn’t itself guarantee that the value of the property has actually changed. When it is emitted is determined by the derived GObject class. If the implementor did not create the property with G_PARAM_EXPLICIT_NOTIFY, then any call to g_object_set_property() results in notify being emitted, even if the new value is the same as the old. If they did pass G_PARAM_EXPLICIT_NOTIFY, then this signal is emitted only when they explicitly call g_object_notify() or g_object_notify_by_pspec(), and common practice is to do that only when the value has actually changed.

    This signal is typically used to obtain change notification for a single property, by specifying the property name as a detail in the g_signal_connect() call, like this:

    (C Language Example):

    g_signal_connect (text_view->buffer, "notify::paste-target-list",
                      G_CALLBACK (gtk_text_view_target_list_notify),
                      text_view)
    

    It is important to note that you must use canonical parameter names as detail strings for the notify signal.

    Note

    This represents the underlying notify::accepts-ps signal

    Declaration

    Swift

    @discardableResult
    @inlinable
    func onNotifyAcceptsPs(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: PrinterRef, _ pspec: ParamSpecRef) -> Void) -> Int

    Parameters

    flags

    Flags

    unownedSelf

    Reference to instance of self

    pspec

    the GParamSpec of the property which changed.

    handler

    The signal handler to call Run the given callback whenever the notifyAcceptsPs signal is emitted

  • notifyAcceptsPsSignal Extension method

    Typed notify::accepts-ps signal for using the connect(signal:) methods

    Declaration

    Swift

    static var notifyAcceptsPsSignal: PrinterSignalName { get }
  • 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.

    Note that getting this signal doesn’t itself guarantee that the value of the property has actually changed. When it is emitted is determined by the derived GObject class. If the implementor did not create the property with G_PARAM_EXPLICIT_NOTIFY, then any call to g_object_set_property() results in notify being emitted, even if the new value is the same as the old. If they did pass G_PARAM_EXPLICIT_NOTIFY, then this signal is emitted only when they explicitly call g_object_notify() or g_object_notify_by_pspec(), and common practice is to do that only when the value has actually changed.

    This signal is typically used to obtain change notification for a single property, by specifying the property name as a detail in the g_signal_connect() call, like this:

    (C Language Example):

    g_signal_connect (text_view->buffer, "notify::paste-target-list",
                      G_CALLBACK (gtk_text_view_target_list_notify),
                      text_view)
    

    It is important to note that you must use canonical parameter names as detail strings for the notify signal.

    Note

    This represents the underlying notify::backend signal

    Declaration

    Swift

    @discardableResult
    @inlinable
    func onNotifyBackend(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: PrinterRef, _ pspec: ParamSpecRef) -> Void) -> Int

    Parameters

    flags

    Flags

    unownedSelf

    Reference to instance of self

    pspec

    the GParamSpec of the property which changed.

    handler

    The signal handler to call Run the given callback whenever the notifyBackend signal is emitted

  • notifyBackendSignal Extension method

    Typed notify::backend signal for using the connect(signal:) methods

    Declaration

    Swift

    static var notifyBackendSignal: PrinterSignalName { get }
  • 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.

    Note that getting this signal doesn’t itself guarantee that the value of the property has actually changed. When it is emitted is determined by the derived GObject class. If the implementor did not create the property with G_PARAM_EXPLICIT_NOTIFY, then any call to g_object_set_property() results in notify being emitted, even if the new value is the same as the old. If they did pass G_PARAM_EXPLICIT_NOTIFY, then this signal is emitted only when they explicitly call g_object_notify() or g_object_notify_by_pspec(), and common practice is to do that only when the value has actually changed.

    This signal is typically used to obtain change notification for a single property, by specifying the property name as a detail in the g_signal_connect() call, like this:

    (C Language Example):

    g_signal_connect (text_view->buffer, "notify::paste-target-list",
                      G_CALLBACK (gtk_text_view_target_list_notify),
                      text_view)
    

    It is important to note that you must use canonical parameter names as detail strings for the notify signal.

    Note

    This represents the underlying notify::icon-name signal

    Declaration

    Swift

    @discardableResult
    @inlinable
    func onNotifyIconName(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: PrinterRef, _ pspec: ParamSpecRef) -> Void) -> Int

    Parameters

    flags

    Flags

    unownedSelf

    Reference to instance of self

    pspec

    the GParamSpec of the property which changed.

    handler

    The signal handler to call Run the given callback whenever the notifyIconName signal is emitted

  • notifyIconNameSignal Extension method

    Typed notify::icon-name signal for using the connect(signal:) methods

    Declaration

    Swift

    static var notifyIconNameSignal: PrinterSignalName { get }
  • 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.

    Note that getting this signal doesn’t itself guarantee that the value of the property has actually changed. When it is emitted is determined by the derived GObject class. If the implementor did not create the property with G_PARAM_EXPLICIT_NOTIFY, then any call to g_object_set_property() results in notify being emitted, even if the new value is the same as the old. If they did pass G_PARAM_EXPLICIT_NOTIFY, then this signal is emitted only when they explicitly call g_object_notify() or g_object_notify_by_pspec(), and common practice is to do that only when the value has actually changed.

    This signal is typically used to obtain change notification for a single property, by specifying the property name as a detail in the g_signal_connect() call, like this:

    (C Language Example):

    g_signal_connect (text_view->buffer, "notify::paste-target-list",
                      G_CALLBACK (gtk_text_view_target_list_notify),
                      text_view)
    

    It is important to note that you must use canonical parameter names as detail strings for the notify signal.

    Note

    This represents the underlying notify::is-virtual signal

    Declaration

    Swift

    @discardableResult
    @inlinable
    func onNotifyIsVirtual(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: PrinterRef, _ pspec: ParamSpecRef) -> Void) -> Int

    Parameters

    flags

    Flags

    unownedSelf

    Reference to instance of self

    pspec

    the GParamSpec of the property which changed.

    handler

    The signal handler to call Run the given callback whenever the notifyIsVirtual signal is emitted

  • notifyIsVirtualSignal Extension method

    Typed notify::is-virtual signal for using the connect(signal:) methods

    Declaration

    Swift

    static var notifyIsVirtualSignal: PrinterSignalName { get }
  • 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.

    Note that getting this signal doesn’t itself guarantee that the value of the property has actually changed. When it is emitted is determined by the derived GObject class. If the implementor did not create the property with G_PARAM_EXPLICIT_NOTIFY, then any call to g_object_set_property() results in notify being emitted, even if the new value is the same as the old. If they did pass G_PARAM_EXPLICIT_NOTIFY, then this signal is emitted only when they explicitly call g_object_notify() or g_object_notify_by_pspec(), and common practice is to do that only when the value has actually changed.

    This signal is typically used to obtain change notification for a single property, by specifying the property name as a detail in the g_signal_connect() call, like this:

    (C Language Example):

    g_signal_connect (text_view->buffer, "notify::paste-target-list",
                      G_CALLBACK (gtk_text_view_target_list_notify),
                      text_view)
    

    It is important to note that you must use canonical parameter names as detail strings for the notify signal.

    Note

    This represents the underlying notify::job-count signal

    Declaration

    Swift

    @discardableResult
    @inlinable
    func onNotifyJobCount(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: PrinterRef, _ pspec: ParamSpecRef) -> Void) -> Int

    Parameters

    flags

    Flags

    unownedSelf

    Reference to instance of self

    pspec

    the GParamSpec of the property which changed.

    handler

    The signal handler to call Run the given callback whenever the notifyJobCount signal is emitted

  • notifyJobCountSignal Extension method

    Typed notify::job-count signal for using the connect(signal:) methods

    Declaration

    Swift

    static var notifyJobCountSignal: PrinterSignalName { get }
  • 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.

    Note that getting this signal doesn’t itself guarantee that the value of the property has actually changed. When it is emitted is determined by the derived GObject class. If the implementor did not create the property with G_PARAM_EXPLICIT_NOTIFY, then any call to g_object_set_property() results in notify being emitted, even if the new value is the same as the old. If they did pass G_PARAM_EXPLICIT_NOTIFY, then this signal is emitted only when they explicitly call g_object_notify() or g_object_notify_by_pspec(), and common practice is to do that only when the value has actually changed.

    This signal is typically used to obtain change notification for a single property, by specifying the property name as a detail in the g_signal_connect() call, like this:

    (C Language Example):

    g_signal_connect (text_view->buffer, "notify::paste-target-list",
                      G_CALLBACK (gtk_text_view_target_list_notify),
                      text_view)
    

    It is important to note that you must use canonical parameter names as detail strings for the notify signal.

    Note

    This represents the underlying notify::location signal

    Declaration

    Swift

    @discardableResult
    @inlinable
    func onNotifyLocation(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: PrinterRef, _ pspec: ParamSpecRef) -> Void) -> Int

    Parameters

    flags

    Flags

    unownedSelf

    Reference to instance of self

    pspec

    the GParamSpec of the property which changed.

    handler

    The signal handler to call Run the given callback whenever the notifyLocation signal is emitted

  • notifyLocationSignal Extension method

    Typed notify::location signal for using the connect(signal:) methods

    Declaration

    Swift

    static var notifyLocationSignal: PrinterSignalName { get }
  • onNotifyName(flags:handler:) Extension method

    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.

    Note that getting this signal doesn’t itself guarantee that the value of the property has actually changed. When it is emitted is determined by the derived GObject class. If the implementor did not create the property with G_PARAM_EXPLICIT_NOTIFY, then any call to g_object_set_property() results in notify being emitted, even if the new value is the same as the old. If they did pass G_PARAM_EXPLICIT_NOTIFY, then this signal is emitted only when they explicitly call g_object_notify() or g_object_notify_by_pspec(), and common practice is to do that only when the value has actually changed.

    This signal is typically used to obtain change notification for a single property, by specifying the property name as a detail in the g_signal_connect() call, like this:

    (C Language Example):

    g_signal_connect (text_view->buffer, "notify::paste-target-list",
                      G_CALLBACK (gtk_text_view_target_list_notify),
                      text_view)
    

    It is important to note that you must use canonical parameter names as detail strings for the notify signal.

    Note

    This represents the underlying notify::name signal

    Declaration

    Swift

    @discardableResult
    @inlinable
    func onNotifyName(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: PrinterRef, _ pspec: ParamSpecRef) -> Void) -> Int

    Parameters

    flags

    Flags

    unownedSelf

    Reference to instance of self

    pspec

    the GParamSpec of the property which changed.

    handler

    The signal handler to call Run the given callback whenever the notifyName signal is emitted

  • notifyNameSignal Extension method

    Typed notify::name signal for using the connect(signal:) methods

    Declaration

    Swift

    static var notifyNameSignal: PrinterSignalName { get }
  • 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.

    Note that getting this signal doesn’t itself guarantee that the value of the property has actually changed. When it is emitted is determined by the derived GObject class. If the implementor did not create the property with G_PARAM_EXPLICIT_NOTIFY, then any call to g_object_set_property() results in notify being emitted, even if the new value is the same as the old. If they did pass G_PARAM_EXPLICIT_NOTIFY, then this signal is emitted only when they explicitly call g_object_notify() or g_object_notify_by_pspec(), and common practice is to do that only when the value has actually changed.

    This signal is typically used to obtain change notification for a single property, by specifying the property name as a detail in the g_signal_connect() call, like this:

    (C Language Example):

    g_signal_connect (text_view->buffer, "notify::paste-target-list",
                      G_CALLBACK (gtk_text_view_target_list_notify),
                      text_view)
    

    It is important to note that you must use canonical parameter names as detail strings for the notify signal.

    Note

    This represents the underlying notify::paused signal

    Declaration

    Swift

    @discardableResult
    @inlinable
    func onNotifyPaused(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: PrinterRef, _ pspec: ParamSpecRef) -> Void) -> Int

    Parameters

    flags

    Flags

    unownedSelf

    Reference to instance of self

    pspec

    the GParamSpec of the property which changed.

    handler

    The signal handler to call Run the given callback whenever the notifyPaused signal is emitted

  • notifyPausedSignal Extension method

    Typed notify::paused signal for using the connect(signal:) methods

    Declaration

    Swift

    static var notifyPausedSignal: PrinterSignalName { get }
  • 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.

    Note that getting this signal doesn’t itself guarantee that the value of the property has actually changed. When it is emitted is determined by the derived GObject class. If the implementor did not create the property with G_PARAM_EXPLICIT_NOTIFY, then any call to g_object_set_property() results in notify being emitted, even if the new value is the same as the old. If they did pass G_PARAM_EXPLICIT_NOTIFY, then this signal is emitted only when they explicitly call g_object_notify() or g_object_notify_by_pspec(), and common practice is to do that only when the value has actually changed.

    This signal is typically used to obtain change notification for a single property, by specifying the property name as a detail in the g_signal_connect() call, like this:

    (C Language Example):

    g_signal_connect (text_view->buffer, "notify::paste-target-list",
                      G_CALLBACK (gtk_text_view_target_list_notify),
                      text_view)
    

    It is important to note that you must use canonical parameter names as detail strings for the notify signal.

    Note

    This represents the underlying notify::state-message signal

    Declaration

    Swift

    @discardableResult
    @inlinable
    func onNotifyStateMessage(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: PrinterRef, _ pspec: ParamSpecRef) -> Void) -> Int

    Parameters

    flags

    Flags

    unownedSelf

    Reference to instance of self

    pspec

    the GParamSpec of the property which changed.

    handler

    The signal handler to call Run the given callback whenever the notifyStateMessage signal is emitted

  • notifyStateMessageSignal Extension method

    Typed notify::state-message signal for using the connect(signal:) methods

    Declaration

    Swift

    static var notifyStateMessageSignal: PrinterSignalName { get }

Printer Class: PrinterProtocol extension (methods and fields)

  • acceptsPdf() Extension method

    Returns whether the printer accepts input in PDF format.

    Declaration

    Swift

    @inlinable
    func acceptsPdf() -> Bool
  • acceptsPs() Extension method

    Returns whether the printer accepts input in PostScript format.

    Declaration

    Swift

    @inlinable
    func acceptsPs() -> Bool
  • compare(b:) Extension method

    Compares two printers.

    Declaration

    Swift

    @inlinable
    func compare<PrinterT>(b: PrinterT) -> Int where PrinterT : PrinterProtocol
  • getBackend() Extension method

    Returns the backend of the printer.

    Declaration

    Swift

    @inlinable
    func getBackend() -> PrintBackendRef!
  • getCapabilities() Extension method

    Returns the printer’s capabilities.

    This is useful when you’re using GtkPrintUnixDialog’s manual-capabilities setting and need to know which settings the printer can handle and which you must handle yourself.

    This will return 0 unless the printer’s details are available, see [methodGtk.Printer.has_details] and [methodGtk.Printer.request_details].

    Declaration

    Swift

    @inlinable
    func getCapabilities() -> PrintCapabilities
  • getDefaultPageSize() Extension method

    Returns default page size of printer.

    Declaration

    Swift

    @inlinable
    func getDefaultPageSize() -> PageSetupRef!
  • getDescription() Extension method

    Gets the description of the printer.

    Declaration

    Swift

    @inlinable
    func getDescription() -> String!
  • Retrieve the hard margins of printer.

    These are the margins that define the area at the borders of the paper that the printer cannot print to.

    Note: This will not succeed unless the printer’s details are available, see [methodGtk.Printer.has_details] and [methodGtk.Printer.request_details].

    Declaration

    Swift

    @inlinable
    func getHardMargins(top: UnsafeMutablePointer<CDouble>!, bottom: UnsafeMutablePointer<CDouble>!, left: UnsafeMutablePointer<CDouble>!, right: UnsafeMutablePointer<CDouble>!) -> Bool
  • Retrieve the hard margins of printer for paper_size.

    These are the margins that define the area at the borders of the paper that the printer cannot print to.

    Note: This will not succeed unless the printer’s details are available, see [methodGtk.Printer.has_details] and [methodGtk.Printer.request_details].

    Declaration

    Swift

    @inlinable
    func getHardMarginsFor<PaperSizeT>(paperSize: PaperSizeT, top: UnsafeMutablePointer<CDouble>!, bottom: UnsafeMutablePointer<CDouble>!, left: UnsafeMutablePointer<CDouble>!, right: UnsafeMutablePointer<CDouble>!) -> Bool where PaperSizeT : PaperSizeProtocol
  • getIconName() Extension method

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

    Declaration

    Swift

    @inlinable
    func getIconName() -> String!
  • getJobCount() Extension method

    Gets the number of jobs currently queued on the printer.

    Declaration

    Swift

    @inlinable
    func getJobCount() -> Int
  • getLocation() Extension method

    Returns a description of the location of the printer.

    Declaration

    Swift

    @inlinable
    func getLocation() -> String!
  • getName() Extension method

    Returns the name of the printer.

    Declaration

    Swift

    @inlinable
    func getName() -> String!
  • getStateMessage() Extension method

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

    Declaration

    Swift

    @inlinable
    func getStateMessage() -> String!
  • hasDetails() Extension method

    Returns whether the printer details are available.

    Declaration

    Swift

    @inlinable
    func hasDetails() -> Bool
  • listPapers() Extension method

    Lists all the paper sizes printer supports.

    This will return and empty list unless the printer’s details are available, see [methodGtk.Printer.has_details] and [methodGtk.Printer.request_details].

    Declaration

    Swift

    @inlinable
    func listPapers() -> GLib.ListRef!
  • requestDetails() Extension method

    Requests the printer details.

    When the details are available, the [signalGtk.Printer::details-acquired] signal will be emitted on printer.

    Declaration

    Swift

    @inlinable
    func requestDetails()
  • backend Extension method

    The backend for the printer.

    Declaration

    Swift

    @inlinable
    var backend: PrintBackendRef! { get }
  • capabilities Extension method

    Returns the printer’s capabilities.

    This is useful when you’re using GtkPrintUnixDialog’s manual-capabilities setting and need to know which settings the printer can handle and which you must handle yourself.

    This will return 0 unless the printer’s details are available, see [methodGtk.Printer.has_details] and [methodGtk.Printer.request_details].

    Declaration

    Swift

    @inlinable
    var capabilities: PrintCapabilities { get }
  • defaultPageSize Extension method

    Returns default page size of printer.

    Declaration

    Swift

    @inlinable
    var defaultPageSize: PageSetupRef! { get }
  • description Extension method

    Gets the description of the printer.

    Declaration

    Swift

    @inlinable
    var description: String! { get }
  • iconName Extension method

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

    Declaration

    Swift

    @inlinable
    var iconName: String! { get }
  • isAcceptingJobs Extension method

    Returns whether the printer is accepting jobs

    Declaration

    Swift

    @inlinable
    var isAcceptingJobs: Bool { get }
  • isActive Extension method

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

    Declaration

    Swift

    @inlinable
    var isActive: Bool { get }
  • isDefault Extension method

    Returns whether the printer is the default printer.

    Declaration

    Swift

    @inlinable
    var isDefault: Bool { get }
  • isPaused Extension method

    Returns whether the printer is currently paused.

    A paused printer still accepts jobs, but it is not printing them.

    Declaration

    Swift

    @inlinable
    var isPaused: Bool { get }
  • isVirtual Extension method

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

    Declaration

    Swift

    @inlinable
    var isVirtual: Bool { get }
  • jobCount Extension method

    Gets the number of jobs currently queued on the printer.

    Declaration

    Swift

    @inlinable
    var jobCount: Int { get }
  • location Extension method

    Information about the location of the printer.

    Declaration

    Swift

    @inlinable
    var location: String! { get }
  • name Extension method

    The name of the printer.

    Declaration

    Swift

    @inlinable
    var name: String! { get }
  • stateMessage Extension method

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

    Declaration

    Swift

    @inlinable
    var stateMessage: String! { get }