summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authormonsta <[email protected]>2016-01-22 15:39:36 +0300
committermonsta <[email protected]>2016-01-22 15:39:36 +0300
commita2c0fe19549c6d08a77ab19d0a370bc09608397e (patch)
treebdc2e31f8f35ed98fb898d9669e2ee9bc32cece4
parent3967123299f476612b6d546b0b31c9293b3d5f26 (diff)
downloadmate-utils-a2c0fe19549c6d08a77ab19d0a370bc09608397e.tar.bz2
mate-utils-a2c0fe19549c6d08a77ab19d0a370bc09608397e.tar.xz
[GTK+3] screenshot: fix deprecated usage of GtkMisc
-rw-r--r--mate-screenshot/src/mate-screenshot.c25
1 files changed, 25 insertions, 0 deletions
diff --git a/mate-screenshot/src/mate-screenshot.c b/mate-screenshot/src/mate-screenshot.c
index 3e121f00..14269d87 100644
--- a/mate-screenshot/src/mate-screenshot.c
+++ b/mate-screenshot/src/mate-screenshot.c
@@ -329,7 +329,12 @@ create_effects_frame (GtkWidget *outer_vbox,
title = g_strconcat ("<b>", frame_title, "</b>", NULL);
label = gtk_label_new (title);
gtk_label_set_use_markup (GTK_LABEL (label), TRUE);
+#if GTK_CHECK_VERSION (3, 16, 0)
+ gtk_label_set_xalign (GTK_LABEL (label), 0.0);
+ gtk_label_set_yalign (GTK_LABEL (label), 0.5);
+#else
gtk_misc_set_alignment (GTK_MISC (label), 0.0, 0.5);
+#endif
gtk_box_pack_start (GTK_BOX (main_vbox), label, FALSE, FALSE, 0);
gtk_widget_show (label);
g_free (title);
@@ -374,7 +379,12 @@ create_effects_frame (GtkWidget *outer_vbox,
label = gtk_label_new_with_mnemonic (_("Apply _effect:"));
gtk_widget_set_sensitive (label, take_window_shot);
+#if GTK_CHECK_VERSION (3, 16, 0)
+ gtk_label_set_xalign (GTK_LABEL (label), 0.0);
+ gtk_label_set_yalign (GTK_LABEL (label), 0.5);
+#else
gtk_misc_set_alignment (GTK_MISC (label), 0.0, 0.5);
+#endif
gtk_box_pack_start (GTK_BOX (hbox), label, FALSE, FALSE, 0);
gtk_widget_show (label);
effect_label = label;
@@ -408,7 +418,12 @@ create_screenshot_frame (GtkWidget *outer_vbox,
title = g_strconcat ("<b>", frame_title, "</b>", NULL);
label = gtk_label_new (title);
gtk_label_set_use_markup (GTK_LABEL (label), TRUE);
+#if GTK_CHECK_VERSION (3, 16, 0)
+ gtk_label_set_xalign (GTK_LABEL (label), 0.0);
+ gtk_label_set_yalign (GTK_LABEL (label), 0.5);
+#else
gtk_misc_set_alignment (GTK_MISC (label), 0.0, 0.5);
+#endif
gtk_box_pack_start (GTK_BOX (main_vbox), label, FALSE, FALSE, 0);
gtk_widget_show (label);
g_free (title);
@@ -476,7 +491,12 @@ create_screenshot_frame (GtkWidget *outer_vbox,
* delay of <spin button> seconds".
*/
label = gtk_label_new_with_mnemonic (_("Grab _after a delay of"));
+#if GTK_CHECK_VERSION (3, 16, 0)
+ gtk_label_set_xalign (GTK_LABEL (label), 0.0);
+ gtk_label_set_yalign (GTK_LABEL (label), 0.5);
+#else
gtk_misc_set_alignment (GTK_MISC (label), 0.0, 0.5);
+#endif
gtk_box_pack_start (GTK_BOX (delay_hbox), label, FALSE, FALSE, 0);
gtk_widget_show (label);
@@ -496,7 +516,12 @@ create_screenshot_frame (GtkWidget *outer_vbox,
* delay of <spin button> seconds".
*/
label = gtk_label_new (_("seconds"));
+#if GTK_CHECK_VERSION (3, 16, 0)
+ gtk_label_set_xalign (GTK_LABEL (label), 0.0);
+ gtk_label_set_yalign (GTK_LABEL (label), 0.5);
+#else
gtk_misc_set_alignment (GTK_MISC (label), 0.0, 0.5);
+#endif
gtk_box_pack_end (GTK_BOX (delay_hbox), label, FALSE, FALSE, 0);
gtk_widget_show (label);
}