![]() |
![]() |
![]() |
GTK+ 3 Reference Manual | ![]() |
---|---|---|---|---|
Top | Description |
#include <gtk/gtkprintunixdialog.h> GtkPrintUnixDialog; GtkWidget * gtk_print_unix_dialog_new (const gchar *title
,GtkWindow *parent
); void gtk_print_unix_dialog_set_page_setup (GtkPrintUnixDialog *dialog
,GtkPageSetup *page_setup
); GtkPageSetup * gtk_print_unix_dialog_get_page_setup (GtkPrintUnixDialog *dialog
); void gtk_print_unix_dialog_set_current_page (GtkPrintUnixDialog *dialog
,gint current_page
); gint gtk_print_unix_dialog_get_current_page (GtkPrintUnixDialog *dialog
); void gtk_print_unix_dialog_set_settings (GtkPrintUnixDialog *dialog
,GtkPrintSettings *settings
); GtkPrintSettings * gtk_print_unix_dialog_get_settings (GtkPrintUnixDialog *dialog
); GtkPrinter * gtk_print_unix_dialog_get_selected_printer (GtkPrintUnixDialog *dialog
); void gtk_print_unix_dialog_add_custom_tab (GtkPrintUnixDialog *dialog
,GtkWidget *child
,GtkWidget *tab_label
); void gtk_print_unix_dialog_set_support_selection (GtkPrintUnixDialog *dialog
,gboolean support_selection
); gboolean gtk_print_unix_dialog_get_support_selection (GtkPrintUnixDialog *dialog
); void gtk_print_unix_dialog_set_has_selection (GtkPrintUnixDialog *dialog
,gboolean has_selection
); gboolean gtk_print_unix_dialog_get_has_selection (GtkPrintUnixDialog *dialog
); void gtk_print_unix_dialog_set_embed_page_setup (GtkPrintUnixDialog *dialog
,gboolean embed
); gboolean gtk_print_unix_dialog_get_embed_page_setup (GtkPrintUnixDialog *dialog
); gboolean gtk_print_unix_dialog_get_page_setup_set (GtkPrintUnixDialog *dialog
); enum GtkPrintCapabilities; void gtk_print_unix_dialog_set_manual_capabilities (GtkPrintUnixDialog *dialog
,GtkPrintCapabilities capabilities
); GtkPrintCapabilities gtk_print_unix_dialog_get_manual_capabilities (GtkPrintUnixDialog *dialog
);
GtkWidget * gtk_print_unix_dialog_new (const gchar *title
,GtkWindow *parent
);
Creates a new GtkPrintUnixDialog.
|
Title of the dialog, or NULL . [allow-none]
|
|
Transient parent of the dialog, or NULL . [allow-none]
|
Returns : |
a new GtkPrintUnixDialog |
Since 2.10
void gtk_print_unix_dialog_set_page_setup (GtkPrintUnixDialog *dialog
,GtkPageSetup *page_setup
);
Sets the page setup of the GtkPrintUnixDialog.
|
a GtkPrintUnixDialog |
|
a GtkPageSetup |
Since 2.10
GtkPageSetup * gtk_print_unix_dialog_get_page_setup
(GtkPrintUnixDialog *dialog
);
Gets the page setup that is used by the GtkPrintUnixDialog.
|
a GtkPrintUnixDialog |
Returns : |
the page setup of dialog . [transfer none]
|
Since 2.10
void gtk_print_unix_dialog_set_current_page (GtkPrintUnixDialog *dialog
,gint current_page
);
Sets the current page number. If current_page
is not -1, this enables
the current page choice for the range of pages to print.
|
a GtkPrintUnixDialog |
|
the current page number. |
Since 2.10
gint gtk_print_unix_dialog_get_current_page
(GtkPrintUnixDialog *dialog
);
Gets the current page of the GtkPrintDialog.
|
a GtkPrintUnixDialog |
Returns : |
the current page of dialog
|
Since 2.10
void gtk_print_unix_dialog_set_settings (GtkPrintUnixDialog *dialog
,GtkPrintSettings *settings
);
Sets the GtkPrintSettings for the GtkPrintUnixDialog. Typically, this is used to restore saved print settings from a previous print operation before the print dialog is shown.
|
a GtkPrintUnixDialog |
|
a GtkPrintSettings, or NULL . [allow-none]
|
Since 2.10
GtkPrintSettings * gtk_print_unix_dialog_get_settings (GtkPrintUnixDialog *dialog
);
Gets a new GtkPrintSettings object that represents the current values in the print dialog. Note that this creates a new object, and you need to unref it if don't want to keep it.
|
a GtkPrintUnixDialog |
Returns : |
a new GtkPrintSettings object with the values from dialog
|
Since 2.10
GtkPrinter * gtk_print_unix_dialog_get_selected_printer
(GtkPrintUnixDialog *dialog
);
Gets the currently selected printer.
|
a GtkPrintUnixDialog |
Returns : |
the currently selected printer. [transfer none] |
Since 2.10
void gtk_print_unix_dialog_add_custom_tab (GtkPrintUnixDialog *dialog
,GtkWidget *child
,GtkWidget *tab_label
);
Adds a custom tab to the print dialog.
|
a GtkPrintUnixDialog |
|
the widget to put in the custom tab |
|
the widget to use as tab label |
Since 2.10
void gtk_print_unix_dialog_set_support_selection (GtkPrintUnixDialog *dialog
,gboolean support_selection
);
Sets whether the print dialog allows user to print a selection.
|
a GtkPrintUnixDialog |
|
TRUE to allow print selection
|
Since 2.18
gboolean gtk_print_unix_dialog_get_support_selection
(GtkPrintUnixDialog *dialog
);
Gets the value of "support-selection" property.
|
a GtkPrintUnixDialog |
Returns : |
whether the application supports print of selection |
Since 2.18
void gtk_print_unix_dialog_set_has_selection (GtkPrintUnixDialog *dialog
,gboolean has_selection
);
Sets whether a selection exists.
|
a GtkPrintUnixDialog |
|
TRUE indicates that a selection exists
|
Since 2.18
gboolean gtk_print_unix_dialog_get_has_selection
(GtkPrintUnixDialog *dialog
);
Gets the value of "has-selection" property.
|
a GtkPrintUnixDialog |
Returns : |
whether there is a selection |
Since 2.18
void gtk_print_unix_dialog_set_embed_page_setup (GtkPrintUnixDialog *dialog
,gboolean embed
);
Embed page size combo box and orientation combo box into page setup page.
|
a GtkPrintUnixDialog |
|
embed page setup selection |
Since 2.18
gboolean gtk_print_unix_dialog_get_embed_page_setup
(GtkPrintUnixDialog *dialog
);
Gets the value of "embed-page-setup" property.
|
a GtkPrintUnixDialog |
Returns : |
whether there is a selection |
Since 2.18
gboolean gtk_print_unix_dialog_get_page_setup_set
(GtkPrintUnixDialog *dialog
);
Gets the page setup that is used by the GtkPrintUnixDialog.
|
a GtkPrintUnixDialog |
Returns : |
whether a page setup was set by user. |
Since 2.18
typedef enum { GTK_PRINT_CAPABILITY_PAGE_SET = 1 << 0, GTK_PRINT_CAPABILITY_COPIES = 1 << 1, GTK_PRINT_CAPABILITY_COLLATE = 1 << 2, GTK_PRINT_CAPABILITY_REVERSE = 1 << 3, GTK_PRINT_CAPABILITY_SCALE = 1 << 4, GTK_PRINT_CAPABILITY_GENERATE_PDF = 1 << 5, GTK_PRINT_CAPABILITY_GENERATE_PS = 1 << 6, GTK_PRINT_CAPABILITY_PREVIEW = 1 << 7, GTK_PRINT_CAPABILITY_NUMBER_UP = 1 << 8, GTK_PRINT_CAPABILITY_NUMBER_UP_LAYOUT = 1 << 9 } GtkPrintCapabilities;
void gtk_print_unix_dialog_set_manual_capabilities (GtkPrintUnixDialog *dialog
,GtkPrintCapabilities capabilities
);
This lets you specify the printing capabilities your application supports. For instance, if you can handle scaling the output then you pass GTK_PRINT_CAPABILITY_SCALE. If you don't pass that, then the dialog will only let you select the scale if the printing system automatically handles scaling.
|
a GtkPrintUnixDialog |
|
the printing capabilities of your application |
Since 2.10
GtkPrintCapabilities gtk_print_unix_dialog_get_manual_capabilities
(GtkPrintUnixDialog *dialog
);
Gets the value of "manual-capabilities" property.
|
a GtkPrintUnixDialog |
Returns : |
the printing capabilities |
Since 2.18