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.
This commit is contained in:
Murray Cumming
2009-07-14 23:46:21 +02:00
parent 33c4cb76d8
commit a14e05fa59
5 changed files with 306 additions and 168 deletions

View File

@ -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");