diff options
author | Matthias Clasen <mclasen@redhat.com> | 2010-11-29 10:14:21 -0500 |
---|---|---|
committer | Matthias Clasen <mclasen@redhat.com> | 2010-11-29 10:14:21 -0500 |
commit | 0ca07a6df736eb9c549f144c3850ee8899638a80 (patch) | |
tree | d121dee18f1ae8df35b82e5a5e9d1d95e3e819a4 /tests/testmerge.c | |
parent | 1f71d641e8c4a0e8315e8ff7105769b9a4d20ded (diff) | |
download | gtk+-0ca07a6df736eb9c549f144c3850ee8899638a80.tar.gz |
Add a GtkSwitch
Diffstat (limited to 'tests/testmerge.c')
-rw-r--r-- | tests/testmerge.c | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/tests/testmerge.c b/tests/testmerge.c index 1e43bb818b..3f1eba0eb2 100644 --- a/tests/testmerge.c +++ b/tests/testmerge.c @@ -592,6 +592,7 @@ main (int argc, char **argv) GtkUIManager *merge; GtkWidget *window, *table, *frame, *menu_box, *vbox, *view; GtkWidget *button, *area, *statusbar; + GtkWidget *box; gint i; gtk_init (&argc, &argv); @@ -652,6 +653,15 @@ main (int argc, char **argv) gtk_action_group_get_action (action_group, "BoldAction")); gtk_widget_show (button); + box = gtk_box_new (GTK_ORIENTATION_HORIZONTAL, 6); + gtk_box_pack_end (GTK_BOX (menu_box), box, FALSE, FALSE, 0); + gtk_container_add (GTK_CONTAINER (box), gtk_label_new ("Bold:")); + button = gtk_switch_new (); + gtk_container_add (GTK_CONTAINER (box), button); + gtk_activatable_set_related_action (GTK_ACTIVATABLE (button), + gtk_action_group_get_action (action_group, "BoldAction")); + gtk_widget_show_all (box); + merge = gtk_ui_manager_new (); g_signal_connect (merge, "connect-proxy", G_CALLBACK (connect_proxy), statusbar); |