[gtk+] gtk-demo/colorsel.c: Do not use GtkAlignment



commit 4a9bd917a0f1edd4a578d81f8433b14877728bba
Author: Javier Jardón <jjardon gnome org>
Date:   Sun Jun 12 23:09:08 2011 +0100

    gtk-demo/colorsel.c: Do not use GtkAlignment

 demos/gtk-demo/colorsel.c |    7 +++----
 1 files changed, 3 insertions(+), 4 deletions(-)
---
diff --git a/demos/gtk-demo/colorsel.c b/demos/gtk-demo/colorsel.c
index f9c119f..860d01f 100644
--- a/demos/gtk-demo/colorsel.c
+++ b/demos/gtk-demo/colorsel.c
@@ -110,12 +110,11 @@ do_colorsel (GtkWidget *do_widget)
 
       gtk_container_add (GTK_CONTAINER (frame), da);
 
-      alignment = gtk_alignment_new (1.0, 0.5, 0.0, 0.0);
-
       button = gtk_button_new_with_mnemonic ("_Change the above color");
-      gtk_container_add (GTK_CONTAINER (alignment), button);
+      gtk_widget_set_halign (button, GTK_ALIGN_END);
+      gtk_widget_set_valign (button, GTK_ALIGN_CENTER);
 
-      gtk_box_pack_start (GTK_BOX (vbox), alignment, FALSE, FALSE, 0);
+      gtk_box_pack_start (GTK_BOX (vbox), button, FALSE, FALSE, 0);
 
       g_signal_connect (button, "clicked",
                         G_CALLBACK (change_color_callback), NULL);



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]