[gtk+] gtk/gtkcolorsel: gtk_misc_set_alignment replacing
- From: Matthias Clasen <matthiasc src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk+] gtk/gtkcolorsel: gtk_misc_set_alignment replacing
- Date: Wed, 1 Jun 2011 00:04:51 +0000 (UTC)
commit 7839c27e13ea35e26f83bdfe105351b43af1d6d5
Author: Diego Celix <dcelix gmail com>
Date: Sat May 21 19:37:26 2011 +0200
gtk/gtkcolorsel: gtk_misc_set_alignment replacing
Replacing the function gtk_misc_set_alignment () with
gtk_widget_set_halign () and gtk_widget_set_valign () in
gtk/gtkcolorsel.c
https://bugzilla.gnome.org/show_bug.cgi?id=650762
gtk/gtkcolorsel.c | 12 ++++++++----
1 files changed, 8 insertions(+), 4 deletions(-)
---
diff --git a/gtk/gtkcolorsel.c b/gtk/gtkcolorsel.c
index febb1a9..0298498 100644
--- a/gtk/gtkcolorsel.c
+++ b/gtk/gtkcolorsel.c
@@ -464,7 +464,8 @@ gtk_color_selection_init (GtkColorSelection *colorsel)
gtk_table_attach_defaults (GTK_TABLE (table), gtk_separator_new (GTK_ORIENTATION_HORIZONTAL), 0, 8, 3, 4);
priv->opacity_label = gtk_label_new_with_mnemonic (_("Op_acity:"));
- gtk_misc_set_alignment (GTK_MISC (priv->opacity_label), 0.0, 0.5);
+ gtk_widget_set_halign (priv->opacity_label, GTK_ALIGN_START);
+ gtk_widget_set_valign (priv->opacity_label, GTK_ALIGN_CENTER);
gtk_table_attach_defaults (GTK_TABLE (table), priv->opacity_label, 0, 1, 4, 5);
adjust = gtk_adjustment_new (0.0, 0.0, 255.0, 1.0, 1.0, 0.0);
g_object_set_data (G_OBJECT (adjust), I_("COLORSEL"), colorsel);
@@ -489,7 +490,8 @@ gtk_color_selection_init (GtkColorSelection *colorsel)
label = gtk_label_new_with_mnemonic (_("Color _name:"));
gtk_table_attach_defaults (GTK_TABLE (table), label, 0, 1, 5, 6);
- gtk_misc_set_alignment (GTK_MISC (label), 0.0, 0.5);
+ gtk_widget_set_halign (label, GTK_ALIGN_START);
+ gtk_widget_set_valign (label, GTK_ALIGN_CENTER);
priv->hex_entry = gtk_entry_new ();
gtk_label_set_mnemonic_widget (GTK_LABEL (label), priv->hex_entry);
@@ -534,7 +536,8 @@ gtk_color_selection_init (GtkColorSelection *colorsel)
set_selected_palette (colorsel, 0, 0);
priv->palette_frame = gtk_box_new (GTK_ORIENTATION_VERTICAL, 6);
label = gtk_label_new_with_mnemonic (_("_Palette:"));
- gtk_misc_set_alignment (GTK_MISC (label), 0.0, 0.5);
+ gtk_widget_set_halign (label, GTK_ALIGN_START);
+ gtk_widget_set_valign (label, GTK_ALIGN_CENTER);
gtk_box_pack_start (GTK_BOX (priv->palette_frame), label, FALSE, FALSE, 0);
gtk_label_set_mnemonic_widget (GTK_LABEL (label),
@@ -2171,7 +2174,8 @@ make_label_spinbutton (GtkColorSelection *colorsel,
label = gtk_label_new_with_mnemonic (text);
gtk_label_set_mnemonic_widget (GTK_LABEL (label), *spinbutton);
- gtk_misc_set_alignment (GTK_MISC (label), 0.0, 0.5);
+ gtk_widget_set_halign (label, GTK_ALIGN_START);
+ gtk_widget_set_valign (label, GTK_ALIGN_CENTER);
gtk_table_attach_defaults (GTK_TABLE (table), label, i, i+1, j, j+1);
gtk_table_attach_defaults (GTK_TABLE (table), *spinbutton, i+1, i+2, j, j+1);
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]