summaryrefslogtreecommitdiff
path: root/src/eom-print-image-setup.c
diff options
context:
space:
mode:
authorStefano Karapetsas <[email protected]>2013-11-30 13:49:54 -0800
committerStefano Karapetsas <[email protected]>2013-11-30 13:49:54 -0800
commit49a08abd4e47acea66d5588b8141703ddb31f22e (patch)
treeb20e6bee1dceb8271fd1eb74e1dd2ea746c734bb /src/eom-print-image-setup.c
parent0de8bb6132dc03846dd2b5dbc24faef7f1b917b4 (diff)
parent225f4493f47f035d706309f715d049789cbfb2c3 (diff)
downloadeom-49a08abd4e47acea66d5588b8141703ddb31f22e.tar.bz2
eom-49a08abd4e47acea66d5588b8141703ddb31f22e.tar.xz
Merge pull request #32 from eyelash/gtk3
improve the GTK3 support
Diffstat (limited to 'src/eom-print-image-setup.c')
-rw-r--r--src/eom-print-image-setup.c22
1 files changed, 12 insertions, 10 deletions
diff --git a/src/eom-print-image-setup.c b/src/eom-print-image-setup.c
index df63b2b..787b214 100644
--- a/src/eom-print-image-setup.c
+++ b/src/eom-print-image-setup.c
@@ -36,8 +36,10 @@
#include "eom-print-image-setup.h"
#include "eom-print-preview.h"
-#if GTK_CHECK_VERSION(3, 0, 0)
- #define gtk_combo_box_new_text() gtk_combo_box_text_new()
+#if !GTK_CHECK_VERSION(2,24,0)
+ #define gtk_combo_box_text_new() gtk_combo_box_new_text()
+ #define gtk_combo_box_text_insert_text(x,y,z) gtk_combo_box_insert_text(x,y,z)
+ #define GTK_COMBO_BOX_TEXT(x) GTK_COMBO_BOX(x)
#endif
/**
@@ -884,14 +886,14 @@ eom_print_image_setup_init (EomPrintImageSetup *setup)
label = gtk_label_new_with_mnemonic (_("C_enter:"));
gtk_misc_set_alignment (GTK_MISC (label), 0.0, 0.5);
- combobox = gtk_combo_box_new_text ();
- gtk_combo_box_insert_text (GTK_COMBO_BOX (combobox),
+ combobox = gtk_combo_box_text_new ();
+ gtk_combo_box_text_insert_text (GTK_COMBO_BOX_TEXT (combobox),
CENTER_NONE, _("None"));
- gtk_combo_box_insert_text (GTK_COMBO_BOX (combobox),
+ gtk_combo_box_text_insert_text (GTK_COMBO_BOX_TEXT (combobox),
CENTER_HORIZONTAL, _("Horizontal"));
- gtk_combo_box_insert_text (GTK_COMBO_BOX (combobox),
+ gtk_combo_box_text_insert_text (GTK_COMBO_BOX_TEXT (combobox),
CENTER_VERTICAL, _("Vertical"));
- gtk_combo_box_insert_text (GTK_COMBO_BOX (combobox),
+ gtk_combo_box_text_insert_text (GTK_COMBO_BOX_TEXT (combobox),
CENTER_BOTH, _("Both"));
gtk_combo_box_set_active (GTK_COMBO_BOX (combobox), CENTER_NONE);
gtk_table_attach (GTK_TABLE (table), label,
@@ -934,10 +936,10 @@ eom_print_image_setup_init (EomPrintImageSetup *setup)
label = gtk_label_new_with_mnemonic (_("_Unit:"));
gtk_misc_set_alignment (GTK_MISC (label), 0.0, 0.5);
- combobox = gtk_combo_box_new_text ();
- gtk_combo_box_insert_text (GTK_COMBO_BOX (combobox), UNIT_MM,
+ combobox = gtk_combo_box_text_new ();
+ gtk_combo_box_text_insert_text (GTK_COMBO_BOX_TEXT (combobox), UNIT_MM,
_("Millimeters"));
- gtk_combo_box_insert_text (GTK_COMBO_BOX (combobox), UNIT_INCH,
+ gtk_combo_box_text_insert_text (GTK_COMBO_BOX_TEXT (combobox), UNIT_INCH,
_("Inches"));
#ifdef HAVE__NL_MEASUREMENT_MEASUREMENT