Nevar pievienot vairāk kā 25 tēmas Tēmai ir jāsākas ar burtu vai ciparu, tā var saturēt domu zīmes ('-') un var būt līdz 35 simboliem gara.

gtkpagesetup.h 4.8 KiB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108
  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. #if defined(GTK_DISABLE_SINGLE_INCLUDES) && !defined (__GTK_H_INSIDE__) && !defined (GTK_COMPILATION)
  21. #error "Only <gtk/gtk.h> can be included directly."
  22. #endif
  23. #ifndef __GTK_PAGE_SETUP_H__
  24. #define __GTK_PAGE_SETUP_H__
  25. #include <gtk/gtkpapersize.h>
  26. G_BEGIN_DECLS
  27. typedef struct _GtkPageSetup GtkPageSetup;
  28. #define GTK_TYPE_PAGE_SETUP (gtk_page_setup_get_type ())
  29. #define GTK_PAGE_SETUP(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), GTK_TYPE_PAGE_SETUP, GtkPageSetup))
  30. #define GTK_IS_PAGE_SETUP(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), GTK_TYPE_PAGE_SETUP))
  31. GType gtk_page_setup_get_type (void) G_GNUC_CONST;
  32. GtkPageSetup * gtk_page_setup_new (void);
  33. GtkPageSetup * gtk_page_setup_copy (GtkPageSetup *other);
  34. GtkPageOrientation gtk_page_setup_get_orientation (GtkPageSetup *setup);
  35. void gtk_page_setup_set_orientation (GtkPageSetup *setup,
  36. GtkPageOrientation orientation);
  37. GtkPaperSize * gtk_page_setup_get_paper_size (GtkPageSetup *setup);
  38. void gtk_page_setup_set_paper_size (GtkPageSetup *setup,
  39. GtkPaperSize *size);
  40. gdouble gtk_page_setup_get_top_margin (GtkPageSetup *setup,
  41. GtkUnit unit);
  42. void gtk_page_setup_set_top_margin (GtkPageSetup *setup,
  43. gdouble margin,
  44. GtkUnit unit);
  45. gdouble gtk_page_setup_get_bottom_margin (GtkPageSetup *setup,
  46. GtkUnit unit);
  47. void gtk_page_setup_set_bottom_margin (GtkPageSetup *setup,
  48. gdouble margin,
  49. GtkUnit unit);
  50. gdouble gtk_page_setup_get_left_margin (GtkPageSetup *setup,
  51. GtkUnit unit);
  52. void gtk_page_setup_set_left_margin (GtkPageSetup *setup,
  53. gdouble margin,
  54. GtkUnit unit);
  55. gdouble gtk_page_setup_get_right_margin (GtkPageSetup *setup,
  56. GtkUnit unit);
  57. void gtk_page_setup_set_right_margin (GtkPageSetup *setup,
  58. gdouble margin,
  59. GtkUnit unit);
  60. void gtk_page_setup_set_paper_size_and_default_margins (GtkPageSetup *setup,
  61. GtkPaperSize *size);
  62. /* These take orientation, but not margins into consideration */
  63. gdouble gtk_page_setup_get_paper_width (GtkPageSetup *setup,
  64. GtkUnit unit);
  65. gdouble gtk_page_setup_get_paper_height (GtkPageSetup *setup,
  66. GtkUnit unit);
  67. /* These take orientation, and margins into consideration */
  68. gdouble gtk_page_setup_get_page_width (GtkPageSetup *setup,
  69. GtkUnit unit);
  70. gdouble gtk_page_setup_get_page_height (GtkPageSetup *setup,
  71. GtkUnit unit);
  72. /* Saving and restoring page setup */
  73. GtkPageSetup *gtk_page_setup_new_from_file (const gchar *file_name,
  74. GError **error);
  75. gboolean gtk_page_setup_load_file (GtkPageSetup *setup,
  76. const char *file_name,
  77. GError **error);
  78. gboolean gtk_page_setup_to_file (GtkPageSetup *setup,
  79. const char *file_name,
  80. GError **error);
  81. GtkPageSetup *gtk_page_setup_new_from_key_file (GKeyFile *key_file,
  82. const gchar *group_name,
  83. GError **error);
  84. gboolean gtk_page_setup_load_key_file (GtkPageSetup *setup,
  85. GKeyFile *key_file,
  86. const gchar *group_name,
  87. GError **error);
  88. void gtk_page_setup_to_key_file (GtkPageSetup *setup,
  89. GKeyFile *key_file,
  90. const gchar *group_name);
  91. G_END_DECLS
  92. #endif /* __GTK_PAGE_SETUP_H__ */