diff options
author | Matthias Clasen <mclasen@redhat.com> | 2011-06-06 22:36:39 -0400 |
---|---|---|
committer | Matthias Clasen <mclasen@redhat.com> | 2011-06-06 22:36:39 -0400 |
commit | 2f7e13067e7f562a4fe92af939674f4554560b67 (patch) | |
tree | 62764547a67c49304ef31d5476a609966e98b5b7 /gtk/gtkprintunixdialog.c | |
parent | 8224287d5c86d00ee46f5a0413235bf984e6f19f (diff) | |
download | gtk+-2f7e13067e7f562a4fe92af939674f4554560b67.tar.gz |
GtkUnixPrintDialog: Don't use GtkAlignment
It is going to be deprecated soon. Instead, use
widget align and margin properties.
Diffstat (limited to 'gtk/gtkprintunixdialog.c')
-rw-r--r-- | gtk/gtkprintunixdialog.c | 15 |
1 files changed, 7 insertions, 8 deletions
diff --git a/gtk/gtkprintunixdialog.c b/gtk/gtkprintunixdialog.c index e3515a01d6..904f2756cf 100644 --- a/gtk/gtkprintunixdialog.c +++ b/gtk/gtkprintunixdialog.c @@ -1198,11 +1198,12 @@ static GtkWidget * wrap_in_frame (const gchar *label, GtkWidget *child) { - GtkWidget *frame, *alignment, *label_widget; + GtkWidget *frame, *label_widget; gchar *bold_text; label_widget = gtk_label_new (NULL); - gtk_misc_set_alignment (GTK_MISC (label_widget), 0.0, 0.5); + gtk_widget_set_halign (label_widget, GTK_ALIGN_START); + gtk_widget_set_valign (label_widget, GTK_ALIGN_CENTER); gtk_widget_show (label_widget); bold_text = g_markup_printf_escaped ("<b>%s</b>", label); @@ -1212,15 +1213,13 @@ wrap_in_frame (const gchar *label, frame = gtk_box_new (GTK_ORIENTATION_VERTICAL, 6); gtk_box_pack_start (GTK_BOX (frame), label_widget, FALSE, FALSE, 0); - alignment = gtk_alignment_new (0.0, 0.0, 1.0, 1.0); - gtk_alignment_set_padding (GTK_ALIGNMENT (alignment), - 0, 0, 12, 0); - gtk_box_pack_start (GTK_BOX (frame), alignment, FALSE, FALSE, 0); + gtk_widget_set_margin_left (child, 12); + gtk_widget_set_halign (child, GTK_ALIGN_FILL); + gtk_widget_set_valign (child, GTK_ALIGN_FILL); - gtk_container_add (GTK_CONTAINER (alignment), child); + gtk_box_pack_start (GTK_BOX (frame), child, FALSE, FALSE, 0); gtk_widget_show (frame); - gtk_widget_show (alignment); return frame; } |