Xfce Foundation Classes
Main Page | Index | Namespace List | Alphabetical List | Class List | File List

# Xfc::Gtk::ComboBoxText Class Reference

A Text Gtk::ComboBox class. More...

`#include <xfc/gtk/combobox.hh>`

Inheritance diagram for Xfc::Gtk::ComboBoxText:

List of all members.

## Public Member Functions

Constructors

- ComboBoxText ()
    Constructs a new text combo box.
- virtual ~ComboBoxText ()
    Destructor.

Accessors

- String get_active_text () const
    Gets the currently active string in combo box.

Methods

- void append (const String &text)
    Appends a string to the list of strings stored in the combo box.
- void prepend (const String &text)
    Prepends a string to the list of strings stored in the combo box.
- void insert (int position, const String &text)
    Inserts a string at position in the list of strings stored in the combo box.
- void remove (int position)
    Removes the string at position from the combo box.

## Detailed Description

A Text Gtk::ComboBox class.

ComboBoxText is a text combo box, which is a Gtk::ComboBox just displaying strings. If you use this text combo box, you should only manipulate its data source with the following convenience methods: append_text(), insert_text(), prepend_text() and remove_text().

See also: the ComboBox HOWTOs and examples.

## Member Function Documentation

void Xfc::Gtk::ComboBoxText::append | ( | const String & | text | ) |

  | Appends a string to the list of strings stored in the combo box. Parameters:
  | text | A text string.

String Xfc::Gtk::ComboBoxText::get_active_text | ( |  | ) | const

| Gets the currently active string in combo box. Returns: A string containing the currently active text, or a null string if none is selected.

void Xfc::Gtk::ComboBoxText::insert | ( | int | position,
|  | const String & | text
| ) |

  | Inserts a string at position in the list of strings stored in the combo box. Parameters:
  | position | An index to insert text.
  | text | A text string.

void Xfc::Gtk::ComboBoxText::prepend | ( | const String & | text | ) |

  | Prepends a string to the list of strings stored in the combo box. Parameters:
  | text | A text string.

void Xfc::Gtk::ComboBoxText::remove | ( | int | position | ) |

  | Removes the string at position from the combo box. Parameters:
  | position | The index of the item to remove.

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

- combobox.hh

Xfce Foundation Classes

Copyright © 2004-2005 The XFC Development Team | XFC 4.3