summaryrefslogtreecommitdiff
path: root/demos
diff options
context:
space:
mode:
authorMurray Cumming <murrayc@murrayc.com>2009-07-14 23:46:21 +0200
committerMurray Cumming <murrayc@murrayc.com>2009-07-14 23:46:49 +0200
commita14e05fa591cffe5043832cc8efefe9ff2691587 (patch)
tree256262dc434cd72965b0b23280758bb7d1cb36cc /demos
parent33c4cb76d86c192ea4dbb8f0db34bbbc37158305 (diff)
downloadgtk+-a14e05fa591cffe5043832cc8efefe9ff2691587.tar.gz
GtkToolItemGroup now has label and label-widget properties.
* demos/gtk-demo/toolpalette.c (load_special_items): Demonstrate gtk_tool_item_group_set_label_widget(). * gtk/gtktoolitemgroup.[h|c]: Rename the "item-group-name" property to "label" because that is what it is. Likewise rename the functions. Add a "label-widget" propert and get/set_label_widget() functions, based on the same code/API in GtkExpander.
Diffstat (limited to 'demos')
-rw-r--r--demos/gtk-demo/toolpalette.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/demos/gtk-demo/toolpalette.c b/demos/gtk-demo/toolpalette.c
index 602fc1e283..5422f0be04 100644
--- a/demos/gtk-demo/toolpalette.c
+++ b/demos/gtk-demo/toolpalette.c
@@ -268,8 +268,13 @@ load_special_items (GtkToolPalette *palette)
{
GtkToolItem *item;
GtkWidget *group;
+ GtkWidget *label_button;
- group = gtk_tool_item_group_new (_("Advanced Features"));
+ group = gtk_tool_item_group_new (NULL);
+ label_button = gtk_button_new_with_label (_("Advanced Features"));
+ gtk_widget_show (label_button);
+ gtk_tool_item_group_set_label_widget (GTK_TOOL_ITEM_GROUP (group),
+ label_button);
gtk_container_add (GTK_CONTAINER (palette), group);
item = create_entry_item ("homogeneous=FALSE");