c++-gtk-utils
|
A print dialog class for FilePrintManager. More...
#include <c++-gtk-utils/file_print_manager.h>
Public Member Functions | |
GtkPrinter * | get_printer () const |
GobjHandle< GtkPrintSettings > | get_settings () const |
GtkPageSetup * | get_page_setup () const |
FilePrintDialog (GtkWindow *parent, GtkPrintSettings *print_settings=0, const char *caption=0, GdkPixbuf *window_icon=0) | |
Public Attributes | |
Emitter | accepted |
Emitter | rejected |
Protected Member Functions | |
virtual void | on_delete_event () |
A print dialog class for FilePrintManager.
Cgu::FilePrintDialog::FilePrintDialog | ( | GtkWindow * | parent, |
GtkPrintSettings * | print_settings = 0 , |
||
const char * | caption = 0 , |
||
GdkPixbuf * | window_icon = 0 |
||
) |
The constructor will not throw. A FIlePrintDialog object must be created in the thread in which the main GTK+ event loop runs.
parent | The parent of the print dialog (NULL may be passed). |
print_settings | The print settings from a previous print job (if any, NULL may be passed if none). |
caption | Window caption (optional, NULL may be passed). |
window_icon | A pixbuf which will comprise the window icon (optional, NULL may be passed). |
GtkPageSetup* Cgu::FilePrintDialog::get_page_setup | ( | ) | const |
Gets the printer page set-up from the print dialog. It will not throw. It must be called in the thread in which the main GTK+ event loop runs.
GtkPrinter* Cgu::FilePrintDialog::get_printer | ( | ) | const |
Gets the currently selected printer from the print dialog. It will not throw. It must be called in the thread in which the main GTK+ event loop runs.
GobjHandle<GtkPrintSettings> Cgu::FilePrintDialog::get_settings | ( | ) | const |
Gets the print settings from the print dialog. It will not throw. It must be called in the thread in which the main GTK+ event loop runs.
virtual void Cgu::FilePrintDialog::on_delete_event | ( | ) | [protected, virtual] |
Closes the dialog, cleans up and emits the rejected Emitter object. It will not throw, even if a method connected to the rejected Emitter object throws (the exception is caught and reported in order to prevent it trying to propagate through the GTK+ event system).
Reimplemented from Cgu::WinBase.
The accepted Emitter object emits if the user choses OK in the print dialog. Emission of accepted by this class will not throw, even if a method connected to the accepted Emitter object throws (the exception is caught and reported in order to prevent it trying to propagate through the GTK+ event system).
The rejected Emitter object emits if the user choses Cancel in the print dialog. Emission of rejected by this class will not throw, even if a method connected to the rejected Emitter object throws (the exception is caught and reported in order to prevent it trying to propagate through the GTK+ event system).