The interface that is used to implement print preview.
A <GtkPrintOperationPreview> object
is passed to the print-operation:preview signal by
<GtkPrintOperation>.
Ends a preview.
This function must be called to finish a custom print preview.
Passed: a
<GtkPrintOperationPreview>.
Returns whether the given page is included in the set of pages that have been selected for printing.
Passed: a
<GtkPrintOperationPreview>.
Passed: a 32-bit integer.
a page number
Returned: a boolean.
#t if the page has been selected for printing
Renders a page to the preview.
This is using the print context that was passed to the
print-operation:preview
handler together with self.
A custom print preview should use this function to render the currently selected page.
Note that this function requires a suitable cairo context to be associated with the print context.
Passed: a
<GtkPrintOperationPreview>.
Passed: a 32-bit integer.
the page to render
Connect a handler with (connect object
print-operation-preview:got-page-size handler). It is called as
(handler self context page-setup).
Emitted once for each page that gets rendered to the preview.
A handler for this signal should update the context according to
page-setup and set up a suitable cairo context, using
print-context:set-cairo-context.
Passed: a
<GtkPrintOperationPreview>.
Passed: a <GtkPrintContext>.
the current <GtkPrintContext>
Passed: a <GtkPageSetup>.
the <GtkPageSetup> for the current page
Connect a handler with (connect object
print-operation-preview:ready handler). It is called as (handler
self context).
The ::ready signal gets emitted once per preview operation, before the first page is rendered.
A handler for this signal can be used for setup tasks.
Passed: a
<GtkPrintOperationPreview>.
Passed: a <GtkPrintContext>.
the current <GtkPrintContext>
Ends a preview.
This function must be called to finish a custom print preview.
To override it in a new class, give register-type #:vfuncs
`((end-preview . ,procedure)). The procedure is called as
(procedure self).
Passed: the class whose implementation to call: a class that implements
<GtkPrintOperationPreview>, or its
GType number.
Passed: a
<GtkPrintOperationPreview>.
To override it in a new class, give register-type #:vfuncs
`((got-page-size . ,procedure)). The procedure is called as
(procedure self context page-setup).
Passed: the class whose implementation to call: a class that implements
<GtkPrintOperationPreview>, or its
GType number.
Passed: a
<GtkPrintOperationPreview>.
Passed: a <GtkPrintContext>.
Passed: a <GtkPageSetup>.
Returns whether the given page is included in the set of pages that have been selected for printing.
To override it in a new class, give register-type #:vfuncs
`((is-selected . ,procedure)). The procedure is called as
(procedure self page-nr) ⇒ %return.
Passed: the class whose implementation to call: a class that implements
<GtkPrintOperationPreview>, or its
GType number.
Passed: a
<GtkPrintOperationPreview>.
Passed: a 32-bit integer.
a page number
Returned: a boolean.
#t if the page has been selected for printing
To override it in a new class, give register-type #:vfuncs
`((ready . ,procedure)). The procedure is called as (procedure
self context).
Passed: the class whose implementation to call: a class that implements
<GtkPrintOperationPreview>, or its
GType number.
Passed: a
<GtkPrintOperationPreview>.
Passed: a <GtkPrintContext>.
Renders a page to the preview.
This is using the print context that was passed to the
print-operation:preview
handler together with self.
A custom print preview should use this function to render the currently selected page.
Note that this function requires a suitable cairo context to be associated with the print context.
To override it in a new class, give register-type #:vfuncs
`((render-page . ,procedure)). The procedure is called as
(procedure self page-nr).
Passed: the class whose implementation to call: a class that implements
<GtkPrintOperationPreview>, or its
GType number.
Passed: a
<GtkPrintOperationPreview>.
Passed: a 32-bit integer.
the page to render