Main Page Widgets Namespaces Book

# Gtk::ComboBoxText Class Reference
[Widgets]

Inheritance diagram for Gtk::ComboBoxText:

[legend]
List of all members.

## Detailed Description

This is a specialisation of the ComboBox which has one column of text (a simple list), and appropriate methods for setting and getting the text.

Note that you can not use this class with Gnome::Glade::Xml::get_widget_derived() to wrap a GtkComboBox added in the Glade user interface designer, because Glade adds its own TreeModel instead of using the TreeModel from this class. You could use a normal Gtk::ComboBox instead, though you can not use Glade to add rows to a TreeModel that is defined in your C++ code.

## Public Member Functions

void | append_text (const Glib::ustring& text)
void | clear ()
| Unsets all the mappings on all renderers on cell_layout and removes all renderers from cell_layout .
| ComboBoxText ()
Glib::ustring | get_active_text () const
void | insert_text (int position, const Glib::ustring& text)
void | prepend_text (const Glib::ustring& text)
void | set_active_text (const Glib::ustring& text)

## Protected Attributes

TextModelColumns | m_text_columns

## Classes

class | TextModelColumns

## Constructor & Destructor Documentation

Gtk::ComboBoxText::ComboBoxText | ( |  | ) |

## Member Function Documentation

void Gtk::ComboBoxText::append_text | ( | const Glib::ustring& | text | ) |

void Gtk::ComboBoxText::clear | ( |  | ) |

| Unsets all the mappings on all renderers on cell_layout and removes all renderers from cell_layout . Since: 2.4 Reimplemented from Gtk::CellLayout.

Glib::ustring Gtk::ComboBoxText::get_active_text | ( |  | ) | const

void Gtk::ComboBoxText::insert_text | ( | int | position,
|  | const Glib::ustring& | text
| ) |

void Gtk::ComboBoxText::prepend_text | ( | const Glib::ustring& | text | ) |

void Gtk::ComboBoxText::set_active_text | ( | const Glib::ustring& | text | ) |

## Member Data Documentation

TextModelColumns Gtk::ComboBoxText::m_text_columns `[protected]`

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

- comboboxtext.h