GtkToolItemGroup — A sub container used in a tool palette
gboolean | collapsed | Read / Write |
PangoEllipsizeMode | ellipsize | Read / Write |
GtkReliefStyle | header-relief | Read / Write |
char * | label | Read / Write |
GtkWidget * | label-widget | Read / Write |
gboolean | expand | Read / Write |
gboolean | fill | Read / Write |
gboolean | homogeneous | Read / Write |
gboolean | new-row | Read / Write |
int | position | Read / Write |
int | expander-size | Read |
int | header-spacing | Read |
struct | GtkToolItemGroup |
struct | GtkToolItemGroupClass |
GObject ╰── GInitiallyUnowned ╰── GtkWidget ╰── GtkContainer ╰── GtkToolItemGroup
GtkToolItemGroup implements AtkImplementorIface, GtkBuildable and GtkToolShell.
#include <gtk/gtk.h>
A GtkToolItemGroup is used together with GtkToolPalette to add GtkToolItems to a palette like container with different categories and drag and drop support.
GtkToolItemGroup has a single CSS node named toolitemgroup.
gboolean
gtk_tool_item_group_get_collapsed (GtkToolItemGroup *group
);
Gets whether group
is collapsed or expanded.
group | a GtkToolItemGroup |
TRUE
if group
is collapsed, FALSE
if it is expanded
Since: 2.20
GtkToolItem * gtk_tool_item_group_get_drop_item (GtkToolItemGroup *group
,gint x
,gint y
);
Gets the tool item at position (x, y).
group | ||
x | the x position | |
y | the y position |
Since: 2.20
PangoEllipsizeMode
gtk_tool_item_group_get_ellipsize (GtkToolItemGroup *group
);
Gets the ellipsization mode of group
.
group |
the PangoEllipsizeMode of group
Since: 2.20
gint gtk_tool_item_group_get_item_position (GtkToolItemGroup *group
,GtkToolItem *item
);
Gets the position of item
in group
as index.
group | ||
item |
the index of item
in group
or -1 if item
is no child of group
Since: 2.20
guint
gtk_tool_item_group_get_n_items (GtkToolItemGroup *group
);
Gets the number of tool items in group
.
group |
the number of tool items in group
Since: 2.20
const gchar *
gtk_tool_item_group_get_label (GtkToolItemGroup *group
);
Gets the label of group
.
group |
the label of group
. The label is an internal string of group
and must not be modified. Note that NULL
is returned if a custom label has been set with gtk_tool_item_group_set_label_widget()
Since: 2.20
GtkWidget *
gtk_tool_item_group_get_label_widget (GtkToolItemGroup *group
);
Gets the label widget of group
. See gtk_tool_item_group_set_label_widget()
.
group |
the label widget of group
.
[transfer none]
Since: 2.20
GtkToolItem * gtk_tool_item_group_get_nth_item (GtkToolItemGroup *group
,guint index
);
Gets the tool item at index
in group.
group | ||
index | the index |
Since: 2.20
GtkReliefStyle
gtk_tool_item_group_get_header_relief (GtkToolItemGroup *group
);
Gets the relief mode of the header button of group
.
group |
the GtkReliefStyle
Since: 2.20
void gtk_tool_item_group_insert (GtkToolItemGroup *group
,GtkToolItem *item
,gint position
);
Inserts item
at position
in the list of children of group
.
group | ||
item | the GtkToolItem to insert into | |
position | the position of |
Since: 2.20
GtkWidget *
gtk_tool_item_group_new (const gchar *label
);
Creates a new tool item group with label label
.
label | the label of the new group |
a new GtkToolItemGroup.
Since: 2.20
void gtk_tool_item_group_set_collapsed (GtkToolItemGroup *group
,gboolean collapsed
);
Sets whether the group
should be collapsed or expanded.
group | ||
collapsed | whether the |
Since: 2.20
void gtk_tool_item_group_set_ellipsize (GtkToolItemGroup *group
,PangoEllipsizeMode ellipsize
);
Sets the ellipsization mode which should be used by labels in group
.
group | ||
ellipsize | the PangoEllipsizeMode labels in |
Since: 2.20
void gtk_tool_item_group_set_item_position (GtkToolItemGroup *group
,GtkToolItem *item
,gint position
);
Sets the position of item
in the list of children of group
.
group | ||
item | the GtkToolItem to move to a new position, should be a child of | |
position | the new position of |
Since: 2.20
void gtk_tool_item_group_set_label (GtkToolItemGroup *group
,const gchar *label
);
Sets the label of the tool item group. The label is displayed in the header of the group.
group | ||
label | the new human-readable label of of the group |
Since: 2.20
void gtk_tool_item_group_set_label_widget (GtkToolItemGroup *group
,GtkWidget *label_widget
);
Sets the label of the tool item group. The label widget is displayed in the header of the group, in place of the usual label.
group | ||
label_widget | the widget to be displayed in place of the usual label |
Since: 2.20
void gtk_tool_item_group_set_header_relief (GtkToolItemGroup *group
,GtkReliefStyle style
);
Set the button relief of the group header. See gtk_button_set_relief()
for details.
group | ||
style | the GtkReliefStyle |
Since: 2.20
struct GtkToolItemGroup;
This should not be accessed directly. Use the accessor functions below.
struct GtkToolItemGroupClass { GtkContainerClass parent_class; };
“collapsed”
property“collapsed” gboolean
Whether the group has been collapsed and items are hidden.
Owner: GtkToolItemGroup
Flags: Read / Write
Default value: FALSE
“ellipsize”
property“ellipsize” PangoEllipsizeMode
Ellipsize for item group headers.
Owner: GtkToolItemGroup
Flags: Read / Write
Default value: PANGO_ELLIPSIZE_NONE
“header-relief”
property“header-relief” GtkReliefStyle
Relief of the group header button.
Owner: GtkToolItemGroup
Flags: Read / Write
Default value: GTK_RELIEF_NORMAL
“label”
property“label” char *
The human-readable title of this item group.
Owner: GtkToolItemGroup
Flags: Read / Write
Default value: ""
“label-widget”
property“label-widget” GtkWidget *
A widget to display in place of the usual label.
Owner: GtkToolItemGroup
Flags: Read / Write
“expand”
child property“expand” gboolean
Whether the item should receive extra space when the group grows.
Owner: GtkToolItemGroup
Flags: Read / Write
Default value: FALSE
“fill”
child property“fill” gboolean
Whether the item should fill the available space.
Owner: GtkToolItemGroup
Flags: Read / Write
Default value: TRUE
“homogeneous”
child property“homogeneous” gboolean
Whether the item should be the same size as other homogeneous items.
Owner: GtkToolItemGroup
Flags: Read / Write
Default value: TRUE
“new-row”
child property“new-row” gboolean
Whether the item should start a new row.
Owner: GtkToolItemGroup
Flags: Read / Write
Default value: FALSE
“position”
child property“position” int
Position of the item within this group.
Owner: GtkToolItemGroup
Flags: Read / Write
Allowed values: >= 0
Default value: 0
“expander-size”
style property“expander-size” int
Size of the expander arrow.
Owner: GtkToolItemGroup
Flags: Read
Allowed values: >= 0
Default value: 16
“header-spacing”
style property“header-spacing” int
Spacing between expander arrow and caption.
Owner: GtkToolItemGroup
Flags: Read
Allowed values: >= 0
Default value: 2
© 2005–2020 The GNOME Project
Licensed under the GNU Lesser General Public License version 2.1 or later.
https://developer.gnome.org/gtk3/3.24/GtkToolItemGroup.html