Main Page Widgets Namespaces Book

# Gtk::Editable Class Reference

Inheritance diagram for Gtk::Editable:

[legend]
List of all members.

## Detailed Description

Base class for text-editing widgets.

The Gtk::Editable class is a base class for widgets for editing text, such as Gtk::Entry. It cannot be instantiated by itself. The editable class contains functions for generically manipulating an editable widget, a large number of action signals used for key bindings, and several signals that an application can connect to to modify the behavior of a widget.

## Public Member Functions

virtual | ~Editable ()
GtkEditable* | gobj ()
| Provides access to the underlying C GObject.
const GtkEditable* | gobj () const
| Provides access to the underlying C GObject.
void | cut_clipboard ()
void | copy_clipboard ()
void | paste_clipboard ()
void | delete_selection ()
void | set_editable (bool is_editable=true)
bool | get_editable () const
| Retrieves whether editable is editable.
void | insert_text (const Glib::ustring& text, int length, int& position)
void | delete_text (int start_pos, int end_pos)
Glib::ustring | get_chars (int start_pos, int end_pos) const
void | select_region (int start_pos, int end_pos)
bool | get_selection_bounds (int& start_pos, int& end_pos) const
void | set_position (int position)
int | get_position () const
Glib::SignalProxy2< void, const Glib::ustring&, int* > | signal_insert_text ()
Glib::SignalProxy2< void, int, int > | signal_delete_text ()
Glib::SignalProxy0<void> | signal_changed ()

## Static Public Member Functions

void | add_interface (GType gtype_implementer)

## Protected Member Functions

virtual void | delete_text_vfunc (int start_pos, int end_pos)
virtual Glib::ustring | get_chars_vfunc (int start_pos, int end_pos) const
virtual void | select_region_vfunc (int start_pos, int end_pos)
virtual bool | get_selection_bounds_vfunc (int& start_pos, int& end_pos) const
virtual void | set_position_vfunc (int position)
virtual int | get_position_vfunc () const
virtual void | insert_text_vfunc (const Glib::ustring& text, int& position)
virtual void | on_insert_text (const Glib::ustring& text, int* position)
virtual void | on_delete_text (int start_pos, int end_pos)
virtual void | on_changed ()

## Related Functions

(Note that these are not member functions.)
Glib::RefPtr<Gtk::Editable> | wrap (GtkEditable* object, bool take_copy=false)

## Constructor & Destructor Documentation

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

## Member Function Documentation

void Gtk::Editable::add_interface | ( | GType | gtype_implementer | ) | `[static]`

void Gtk::Editable::copy_clipboard | ( |  | ) |

void Gtk::Editable::cut_clipboard | ( |  | ) |

void Gtk::Editable::delete_selection | ( |  | ) |

void Gtk::Editable::delete_text | ( | int | start_pos,
|  | int | end_pos
| ) |

virtual void Gtk::Editable::delete_text_vfunc | ( | int | start_pos,
|  | int | end_pos
| ) | `[protected, virtual]`

Glib::ustring Gtk::Editable::get_chars | ( | int | start_pos,
|  | int | end_pos
| ) | const

virtual Glib::ustring Gtk::Editable::get_chars_vfunc | ( | int | start_pos,
|  | int | end_pos
| ) | const`[protected, virtual]`

bool Gtk::Editable::get_editable | ( |  | ) | const

Retrieves whether editable is editable.

See set_editable().

Returns:
  `true` if editable is editable.

int Gtk::Editable::get_position | ( |  | ) | const

virtual int Gtk::Editable::get_position_vfunc | ( |  | ) | const`[protected, virtual]`

bool Gtk::Editable::get_selection_bounds | ( | int& | start_pos,
|  | int& | end_pos
| ) | const

virtual bool Gtk::Editable::get_selection_bounds_vfunc | ( | int& | start_pos,
|  | int& | end_pos
| ) | const`[protected, virtual]`

const GtkEditable* Gtk::Editable::gobj | ( |  | ) | const`[inline]`

| Provides access to the underlying C GObject. Reimplemented from Glib::Interface. Reimplemented in Gtk::Entry, and Gtk::SpinButton.

GtkEditable* Gtk::Editable::gobj | ( |  | ) | `[inline]`

| Provides access to the underlying C GObject. Reimplemented from Glib::Interface. Reimplemented in Gtk::Entry, and Gtk::SpinButton.

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

virtual void Gtk::Editable::insert_text_vfunc | ( | const Glib::ustring& | text,
|  | int& | position
| ) | `[protected, virtual]`

virtual void Gtk::Editable::on_changed | ( |  | ) | `[protected, virtual]`

virtual void Gtk::Editable::on_delete_text | ( | int | start_pos,
|  | int | end_pos
| ) | `[protected, virtual]`

virtual void Gtk::Editable::on_insert_text | ( | const Glib::ustring& | text,
|  | int* | position
| ) | `[protected, virtual]`

void Gtk::Editable::paste_clipboard | ( |  | ) |

void Gtk::Editable::select_region | ( | int | start_pos,
|  | int | end_pos
| ) |

virtual void Gtk::Editable::select_region_vfunc | ( | int | start_pos,
|  | int | end_pos
| ) | `[protected, virtual]`

void Gtk::Editable::set_editable | ( | bool | is_editable = `true` | ) |

void Gtk::Editable::set_position | ( | int | position | ) |

virtual void Gtk::Editable::set_position_vfunc | ( | int | position | ) | `[protected, virtual]`

Glib::SignalProxy0<void> Gtk::Editable::signal_changed | ( |  | ) |

Glib::SignalProxy2<void,int,int> Gtk::Editable::signal_delete_text | ( |  | ) |

Glib::SignalProxy2<void,const Glib::ustring&,int*> Gtk::Editable::signal_insert_text | ( |  | ) |

## Friends And Related Function Documentation

Glib::RefPtr<Gtk::Editable> wrap | ( | GtkEditable* | object,
|  | bool | take_copy = `false`
| ) | `[related]`

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:

- editable.h