gtkmm 2.24.4

- Main Page
- Related Pages
- Modules
- Namespaces
- Classes

- Class List
- Class Index
- Class Hierarchy
- Class Members

Public Member Functions | Related Functions

# Gtk::ToolItemGroup Class Reference
Widgets | Container Widgets

A ToolItemGroup is used together with ToolPalette to add ToolItems to a palette-like container with different categories and drag and drop support. More...

Inheritance diagram for Gtk::ToolItemGroup:
[legend]
Collaboration diagram for Gtk::ToolItemGroup:
[legend]

List of all members.

## Public Member Functions
virtual | ~ToolItemGroup ()
GtkToolItemGroup* | gobj ()
| Provides access to the underlying C GtkObject.
const GtkToolItemGroup* | gobj () const
| Provides access to the underlying C GtkObject.
| ToolItemGroup (const Glib::ustring& label=Glib::ustring())
void | set_label (const Glib::ustring& label)
| Sets the label of the tool item group.
void | set_label_widget (Widget& label_widget)
| Sets the label of the tool item group.
void | set_collapsed (bool collapsed=true)
| Sets whether the group should be collapsed or expanded.
void | set_ellipsize (Pango::EllipsizeMode ellipsize)
| Sets the ellipsization mode which should be used by labels in group.
void | set_header_relief (ReliefStyle style)
| Set the button relief of the group header.
Glib::ustring | get_label () const
| Gets the label of group.
Widget* | get_label_widget ()
| Gets the label widget of group.
const Widget* | get_label_widget () const
| Gets the label widget of group.
bool | get_collapsed () const
| Gets whether group is collapsed or expanded.
Pango::EllipsizeMode | get_ellipsize () const
| Gets the ellipsization mode of group.
ReliefStyle | get_header_relief () const
| Gets the relief mode of the header button of group.
void | insert (ToolItem& item, int position)
| Inserts item at position in the list of children of group.
void | insert (ToolItem& item)
| Inserts item at the end of the list of children of the group.
void | set_item_position (ToolItem& item, int position)
| Sets the position of item in the list of children of group.
int | get_item_position (const ToolItem& item) const
| Gets the position of item in group as index.
guint | get_n_items () const
| Gets the number of tool items in group.
ToolItem* | get_nth_item (guint index)
| Gets the tool item at index in group.
const ToolItem* | get_nth_item (guint index) const
| Gets the tool item at index in group.
ToolItem* | get_drop_item (int x, int y)
| Gets the tool item at position (x, y).
ToolItem* | get_drop_item (int x, int y) const
| Gets the tool item at position (x, y).
Glib::PropertyProxy < Glib::ustring > | property_label ()
| The human-readable title of this item group.
Glib::PropertyProxy_ReadOnly < Glib::ustring > | property_label () const
| The human-readable title of this item group.
Glib::PropertyProxy < Gtk::Widget* > | property_label_widget ()
| A widget to display in place of the usual label.
Glib::PropertyProxy_ReadOnly < Gtk::Widget* > | property_label_widget () const
| A widget to display in place of the usual label.
Glib::PropertyProxy< bool > | property_collapsed ()
| Whether the group has been collapsed and items are hidden.
Glib::PropertyProxy_ReadOnly < bool > | property_collapsed () const
| Whether the group has been collapsed and items are hidden.
Glib::PropertyProxy < Pango::EllipsizeMode > | property_ellipsize ()
| Ellipsize for item group headers.
Glib::PropertyProxy_ReadOnly < Pango::EllipsizeMode > | property_ellipsize () const
| Ellipsize for item group headers.
Glib::PropertyProxy< ReliefStyle > | property_header_relief ()
| Relief of the group header button.
Glib::PropertyProxy_ReadOnly < ReliefStyle > | property_header_relief () const
| Relief of the group header button.
## Related Functions
(Note that these are not member functions.)
Gtk::ToolItemGroup* | wrap (GtkToolItemGroup* object, bool take_copy=false)
| A Glib::wrap() method for this object.

## Detailed Description

A ToolItemGroup is used together with ToolPalette to add ToolItems to a palette-like container with different categories and drag and drop support.

Since gtkmm 2.20:

## Constructor & Destructor Documentation

virtual Gtk::ToolItemGroup::~ToolItemGroup | ( |  | ) | `[virtual]`

Gtk::ToolItemGroup::ToolItemGroup | ( | const Glib::ustring & | label = `Glib::ustring()` | ) | `[explicit]`

## Member Function Documentation

bool Gtk::ToolItemGroup::get_collapsed | ( |  | ) | const

Gets whether group is collapsed or expanded.

Since gtkmm 2.20:

Returns:
  `true` if group is collapsed, `false` if it is expanded.

ToolItem* Gtk::ToolItemGroup::get_drop_item | ( | int | x,
|  | int | y
| ) |  |

Gets the tool item at position (x, y).

Since gtkmm 2.20:

Parameters:

  x | The x position.
  y | The y position.

Returns:
  The Gtk::ToolItem at position (x, y).

ToolItem* Gtk::ToolItemGroup::get_drop_item | ( | int | x,
|  | int | y
| ) |  | const

Gets the tool item at position (x, y).

Since gtkmm 2.20:

Parameters:

  x | The x position.
  y | The y position.

Returns:
  The Gtk::ToolItem at position (x, y).

Pango::EllipsizeMode Gtk::ToolItemGroup::get_ellipsize | ( |  | ) | const

Gets the ellipsization mode of group.

Since gtkmm 2.20:

Returns:
  The Pango::EllipsizeMode of group.

ReliefStyle Gtk::ToolItemGroup::get_header_relief | ( |  | ) | const

Gets the relief mode of the header button of group.

Since gtkmm 2.20:

Returns:
  The Gtk::ReliefStyle.

int Gtk::ToolItemGroup::get_item_position | ( | const ToolItem& | item | ) | const

Gets the position of item in group as index.

Since gtkmm 2.20:

Parameters:

  item | A Gtk::ToolItem.

Returns:
  The index of item in group or -1 if item is no child of group.

Glib::ustring Gtk::ToolItemGroup::get_label | ( |  | ) | const

Gets the label of group.

Since gtkmm 2.20:

Returns:
  The label of group. The label is an internal string of group and must not be modified. Note that `0` is returned if a custom label has been set with set_label_widget().

Widget* Gtk::ToolItemGroup::get_label_widget | ( |  | ) |

Gets the label widget of group.

See set_label_widget().

Since gtkmm 2.20:

Returns:
  The label widget of group.

const Widget* Gtk::ToolItemGroup::get_label_widget | ( |  | ) | const

Gets the label widget of group.

See set_label_widget().

Since gtkmm 2.20:

Returns:
  The label widget of group.

guint Gtk::ToolItemGroup::get_n_items | ( |  | ) | const

Gets the number of tool items in group.

Since gtkmm 2.20:

Returns:
  The number of tool items in group.

ToolItem* Gtk::ToolItemGroup::get_nth_item | ( | guint | index | ) |

Gets the tool item at index in group.

Since gtkmm 2.20:

Parameters:

  index | The index.

Returns:
  The Gtk::ToolItem at index.

const ToolItem* Gtk::ToolItemGroup::get_nth_item | ( | guint | index | ) | const

Gets the tool item at index in group.

Since gtkmm 2.20:

Parameters:

  index | The index.

Returns:
  The Gtk::ToolItem at index.

GtkToolItemGroup* Gtk::ToolItemGroup::gobj | ( |  | ) | `[inline]`

Provides access to the underlying C GtkObject.

Reimplemented from Gtk::Container.

const GtkToolItemGroup* Gtk::ToolItemGroup::gobj | ( |  | ) | const`[inline]`

Provides access to the underlying C GtkObject.

Reimplemented from Gtk::Container.

void Gtk::ToolItemGroup::insert | ( | ToolItem& | item,
|  | int | position
| ) |  |

Inserts item at position in the list of children of group.

Since gtkmm 2.20:

Parameters:

  item | The Gtk::ToolItem to insert into group.
  position | The position of item in group, starting with 0. The position -1 means end of list.

void Gtk::ToolItemGroup::insert | ( | ToolItem& | item | ) |

Inserts item at the end of the list of children of the group.

Parameters:

  item | The ToolItem to insert into the group.

Glib::PropertyProxy<bool> Gtk::ToolItemGroup::property_collapsed | ( |  | ) |

Whether the group has been collapsed and items are hidden.

You rarely need to use properties because there are get_ and set_ methods for almost all of them.

Returns:
  A PropertyProxy that allows you to get or set the property of the value, or receive notification when the value of the property changes.

Glib::PropertyProxy_ReadOnly<bool> Gtk::ToolItemGroup::property_collapsed | ( |  | ) | const

Whether the group has been collapsed and items are hidden.

You rarely need to use properties because there are get_ and set_ methods for almost all of them.

Returns:
  A PropertyProxy that allows you to get or set the property of the value, or receive notification when the value of the property changes.

Glib::PropertyProxy_ReadOnly<Pango::EllipsizeMode> Gtk::ToolItemGroup::property_ellipsize | ( |  | ) | const

Ellipsize for item group headers.

You rarely need to use properties because there are get_ and set_ methods for almost all of them.

Returns:
  A PropertyProxy that allows you to get or set the property of the value, or receive notification when the value of the property changes.

Glib::PropertyProxy<Pango::EllipsizeMode> Gtk::ToolItemGroup::property_ellipsize | ( |  | ) |

Ellipsize for item group headers.

You rarely need to use properties because there are get_ and set_ methods for almost all of them.

Returns:
  A PropertyProxy that allows you to get or set the property of the value, or receive notification when the value of the property changes.

Glib::PropertyProxy_ReadOnly<ReliefStyle> Gtk::ToolItemGroup::property_header_relief | ( |  | ) | const

Relief of the group header button.

You rarely need to use properties because there are get_ and set_ methods for almost all of them.

Returns:
  A PropertyProxy that allows you to get or set the property of the value, or receive notification when the value of the property changes.

Glib::PropertyProxy<ReliefStyle> Gtk::ToolItemGroup::property_header_relief | ( |  | ) |

Relief of the group header button.

You rarely need to use properties because there are get_ and set_ methods for almost all of them.

Returns:
  A PropertyProxy that allows you to get or set the property of the value, or receive notification when the value of the property changes.

Glib::PropertyProxy<Glib::ustring> Gtk::ToolItemGroup::property_label | ( |  | ) |

The human-readable title of this item group.

You rarely need to use properties because there are get_ and set_ methods for almost all of them.

Returns:
  A PropertyProxy that allows you to get or set the property of the value, or receive notification when the value of the property changes.

Glib::PropertyProxy_ReadOnly<Glib::ustring> Gtk::ToolItemGroup::property_label | ( |  | ) | const

The human-readable title of this item group.

You rarely need to use properties because there are get_ and set_ methods for almost all of them.

Returns:
  A PropertyProxy that allows you to get or set the property of the value, or receive notification when the value of the property changes.

Glib::PropertyProxy<Gtk::Widget*> Gtk::ToolItemGroup::property_label_widget | ( |  | ) |

A widget to display in place of the usual label.

You rarely need to use properties because there are get_ and set_ methods for almost all of them.

Returns:
  A PropertyProxy that allows you to get or set the property of the value, or receive notification when the value of the property changes.

Glib::PropertyProxy_ReadOnly<Gtk::Widget*> Gtk::ToolItemGroup::property_label_widget | ( |  | ) | const

A widget to display in place of the usual label.

You rarely need to use properties because there are get_ and set_ methods for almost all of them.

Returns:
  A PropertyProxy that allows you to get or set the property of the value, or receive notification when the value of the property changes.

void Gtk::ToolItemGroup::set_collapsed | ( | bool | collapsed = `true` | ) |

Sets whether the group should be collapsed or expanded.

Since gtkmm 2.20:

Parameters:

  collapsed | Whether the group should be collapsed or expanded.

void Gtk::ToolItemGroup::set_ellipsize | ( | Pango::EllipsizeMode | ellipsize | ) |

Sets the ellipsization mode which should be used by labels in group.

Since gtkmm 2.20:

Parameters:

  ellipsize | The Pango::EllipsizeMode labels in group should use.

void Gtk::ToolItemGroup::set_header_relief | ( | ReliefStyle | style | ) |

Set the button relief of the group header.

See Gtk::Button::set_relief() for details.

Since gtkmm 2.20:

Parameters:

  style | The Gtk::ReliefStyle.

void Gtk::ToolItemGroup::set_item_position | ( | ToolItem& | item,
|  | int | position
| ) |  |

Sets the position of item in the list of children of group.

Since gtkmm 2.20:

Parameters:

  item | The Gtk::ToolItem to move to a new position, should be a child of group.
  position | The new position of item in group, starting with 0. The position -1 means end of list.

void Gtk::ToolItemGroup::set_label | ( | const Glib::ustring & | label | ) |

Sets the label of the tool item group.

The label is displayed in the header of the group.

Since gtkmm 2.20:

Parameters:

  label | The new human-readable label of of the group.

void Gtk::ToolItemGroup::set_label_widget | ( | Widget& | 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.

Since gtkmm 2.20:

Parameters:

  label_widget | The widget to be displayed in place of the usual label.

## Friends And Related Function Documentation

Gtk::ToolItemGroup* wrap | ( | GtkToolItemGroup * | object,
|  | bool | take_copy = `false`
| ) |  | `[related]`

A Glib::wrap() method for this object.

Parameters:

  object | The C instance.
  take_copy | False if the result should take ownership of the C instance. True if it should take a new copy or ref.

Returns:
  A C++ instance that wraps this C instance.

The documentation for this class was generated from the following file:

- gtkmm/toolitemgroup.h