X-Git-Url: http://pileus.org/git/?a=blobdiff_plain;f=gtk%2Fgtkprintjob.h;h=0c19802620e3dfea38d924035f6bd4623e1cf78e;hb=a89d420270d1a856e072ed87c365b0176f102e6c;hp=89a3d5bc4c18a31a6e8a7aa8e022aec8f1a66f98;hpb=a1b53272fd805a1c5a984873d39f5dc23e8dd967;p=~andy%2Fgtk
diff --git a/gtk/gtkprintjob.h b/gtk/gtkprintjob.h
index 89a3d5bc4..0c1980262 100644
--- a/gtk/gtkprintjob.h
+++ b/gtk/gtkprintjob.h
@@ -1,5 +1,5 @@
-/* GtkPrintJob
- * Copyright (C) 2006 Red Hat,Inc.
+/* GtkPrintJob
+ * Copyright (C) 2006 Red Hat,Inc.
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
@@ -12,18 +12,20 @@
* Lesser General Public License for more details.
*
* You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the
- * Free Software Foundation, Inc., 59 Temple Place - Suite 330,
- * Boston, MA 02111-1307, USA.
+ * License along with this library. If not, see .
*/
+
#ifndef __GTK_PRINT_JOB_H__
#define __GTK_PRINT_JOB_H__
-#include
+#if !defined (__GTK_UNIX_PRINT_H_INSIDE__) && !defined (GTK_COMPILATION)
+#error "Only can be included directly."
+#endif
+
#include
+#include
#include
-#include
G_BEGIN_DECLS
@@ -38,9 +40,19 @@ typedef struct _GtkPrintJob GtkPrintJob;
typedef struct _GtkPrintJobClass GtkPrintJobClass;
typedef struct _GtkPrintJobPrivate GtkPrintJobPrivate;
-typedef void (*GtkPrintJobCompleteFunc) (GtkPrintJob *print_job,
- gpointer user_data,
- GError *error);
+/**
+ * GtkPrintJobCompleteFunc:
+ * @print_job: the #GtkPrintJob
+ * @user_data: user data that has been passed to gtk_print_job_send()
+ * @error: a #GError that contains error information if the sending
+ * of the print job failed, otherwise %NULL
+ *
+ * The type of callback that is passed to gtk_print_job_send().
+ * It is called when the print job has been completely sent.
+ */
+typedef void (*GtkPrintJobCompleteFunc) (GtkPrintJob *print_job,
+ gpointer user_data,
+ const GError *error);
struct _GtkPrinter;
@@ -49,19 +61,6 @@ struct _GtkPrintJob
GObject parent_instance;
GtkPrintJobPrivate *priv;
-
- /* Settings the client has to implement:
- * (These are read-only, set at initialization)
- */
- GtkPrintPages print_pages;
- GtkPageRange *page_ranges;
- gint num_page_ranges;
- GtkPageSet page_set;
- gint num_copies;
- gdouble scale;
- guint rotate_to_orientation : 1;
- guint collate : 1;
- guint reverse : 1;
};
struct _GtkPrintJobClass
@@ -75,9 +74,6 @@ struct _GtkPrintJobClass
void (*_gtk_reserved2) (void);
void (*_gtk_reserved3) (void);
void (*_gtk_reserved4) (void);
- void (*_gtk_reserved5) (void);
- void (*_gtk_reserved6) (void);
- void (*_gtk_reserved7) (void);
};
GType gtk_print_job_get_type (void) G_GNUC_CONST;
@@ -87,7 +83,7 @@ GtkPrintJob *gtk_print_job_new (const gchar
GtkPageSetup *page_setup);
GtkPrintSettings *gtk_print_job_get_settings (GtkPrintJob *job);
GtkPrinter *gtk_print_job_get_printer (GtkPrintJob *job);
-G_CONST_RETURN gchar *gtk_print_job_get_title (GtkPrintJob *job);
+const gchar * gtk_print_job_get_title (GtkPrintJob *job);
GtkPrintStatus gtk_print_job_get_status (GtkPrintJob *job);
gboolean gtk_print_job_set_source_file (GtkPrintJob *job,
const gchar *filename,
@@ -102,6 +98,39 @@ void gtk_print_job_send (GtkPrintJob
gpointer user_data,
GDestroyNotify dnotify);
+GtkPrintPages gtk_print_job_get_pages (GtkPrintJob *job);
+void gtk_print_job_set_pages (GtkPrintJob *job,
+ GtkPrintPages pages);
+GtkPageRange * gtk_print_job_get_page_ranges (GtkPrintJob *job,
+ gint *n_ranges);
+void gtk_print_job_set_page_ranges (GtkPrintJob *job,
+ GtkPageRange *ranges,
+ gint n_ranges);
+GtkPageSet gtk_print_job_get_page_set (GtkPrintJob *job);
+void gtk_print_job_set_page_set (GtkPrintJob *job,
+ GtkPageSet page_set);
+gint gtk_print_job_get_num_copies (GtkPrintJob *job);
+void gtk_print_job_set_num_copies (GtkPrintJob *job,
+ gint num_copies);
+gdouble gtk_print_job_get_scale (GtkPrintJob *job);
+void gtk_print_job_set_scale (GtkPrintJob *job,
+ gdouble scale);
+guint gtk_print_job_get_n_up (GtkPrintJob *job);
+void gtk_print_job_set_n_up (GtkPrintJob *job,
+ guint n_up);
+GtkNumberUpLayout gtk_print_job_get_n_up_layout (GtkPrintJob *job);
+void gtk_print_job_set_n_up_layout (GtkPrintJob *job,
+ GtkNumberUpLayout layout);
+gboolean gtk_print_job_get_rotate (GtkPrintJob *job);
+void gtk_print_job_set_rotate (GtkPrintJob *job,
+ gboolean rotate);
+gboolean gtk_print_job_get_collate (GtkPrintJob *job);
+void gtk_print_job_set_collate (GtkPrintJob *job,
+ gboolean collate);
+gboolean gtk_print_job_get_reverse (GtkPrintJob *job);
+void gtk_print_job_set_reverse (GtkPrintJob *job,
+ gboolean reverse);
+
G_END_DECLS
#endif /* __GTK_PRINT_JOB_H__ */