]> Pileus Git - ~andy/gtk/blob - gtk/gtkpagesetup.h
Merge the gtk-printing branch. For more detailed ChangeLog entries, see
[~andy/gtk] / gtk / gtkpagesetup.h
1 /* GTK - The GIMP Toolkit
2  * gtkpagesetup.h: Page Setup
3  * Copyright (C) 2006, Red Hat, Inc.
4  *
5  * This library is free software; you can redistribute it and/or
6  * modify it under the terms of the GNU Lesser General Public
7  * License as published by the Free Software Foundation; either
8  * version 2 of the License, or (at your option) any later version.
9  *
10  * This library is distributed in the hope that it will be useful,
11  * but WITHOUT ANY WARRANTY; without even the implied warranty of
12  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
13  * Lesser General Public License for more details.
14  *
15  * You should have received a copy of the GNU Lesser General Public
16  * License along with this library; if not, write to the
17  * Free Software Foundation, Inc., 59 Temple Place - Suite 330,
18  * Boston, MA 02111-1307, USA.
19  */
20
21 #ifndef __GTK_PAGE_SETUP_H__
22 #define __GTK_PAGE_SETUP_H__
23
24 #include <glib-object.h>
25 #include "gtkenums.h"
26 #include "gtkpapersize.h"
27
28 G_BEGIN_DECLS
29
30 typedef struct _GtkPageSetup GtkPageSetup;
31
32 #define GTK_TYPE_PAGE_SETUP    (gtk_page_setup_get_type ())
33 #define GTK_PAGE_SETUP(obj)    (G_TYPE_CHECK_INSTANCE_CAST ((obj), GTK_TYPE_PAGE_SETUP, GtkPageSetup))
34 #define GTK_IS_PAGE_SETUP(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), GTK_TYPE_PAGE_SETUP))
35
36 GType              gtk_page_setup_get_type          (void) G_GNUC_CONST;
37 GtkPageSetup *     gtk_page_setup_new               (void);
38 GtkPageSetup *     gtk_page_setup_copy              (GtkPageSetup       *other);
39 GtkPageOrientation gtk_page_setup_get_orientation   (GtkPageSetup       *setup);
40 void               gtk_page_setup_set_orientation   (GtkPageSetup       *setup,
41                                                      GtkPageOrientation  orientation);
42 GtkPaperSize *     gtk_page_setup_get_paper_size    (GtkPageSetup       *setup);
43 void               gtk_page_setup_set_paper_size    (GtkPageSetup       *setup,
44                                                      GtkPaperSize       *size);
45 double             gtk_page_setup_get_top_margin    (GtkPageSetup       *setup,
46                                                      GtkUnit             unit);
47 void               gtk_page_setup_set_top_margin    (GtkPageSetup       *setup,
48                                                      double              margin,
49                                                      GtkUnit             unit);
50 double             gtk_page_setup_get_bottom_margin (GtkPageSetup       *setup,
51                                                      GtkUnit             unit);
52 void               gtk_page_setup_set_bottom_margin (GtkPageSetup       *setup,
53                                                      double              margin,
54                                                      GtkUnit             unit);
55 double             gtk_page_setup_get_left_margin   (GtkPageSetup       *setup,
56                                                      GtkUnit             unit);
57 void               gtk_page_setup_set_left_margin   (GtkPageSetup       *setup,
58                                                      double              margin,
59                                                      GtkUnit             unit);
60 double             gtk_page_setup_get_right_margin  (GtkPageSetup       *setup,
61                                                      GtkUnit             unit);
62 void               gtk_page_setup_set_right_margin  (GtkPageSetup       *setup,
63                                                      double              margin,
64                                                      GtkUnit             unit);
65
66 void gtk_page_setup_set_paper_size_and_default_margins (GtkPageSetup *setup,
67                                                         GtkPaperSize *size);
68
69 /* These take orientation, but not margins into consideration */
70 double             gtk_page_setup_get_paper_width   (GtkPageSetup       *setup,
71                                                      GtkUnit             unit);
72 double             gtk_page_setup_get_paper_height  (GtkPageSetup       *setup,
73                                                      GtkUnit             unit);
74
75
76 /* These take orientation, and margins into consideration */
77 double             gtk_page_setup_get_page_width    (GtkPageSetup       *setup,
78                                                      GtkUnit             unit);
79 double             gtk_page_setup_get_page_height   (GtkPageSetup       *setup,
80                                                      GtkUnit             unit);
81
82
83 G_END_DECLS
84
85 #endif /* __GTK_PAGE_SETUP_H__ */