gtkmm 3.24.7
|
Interface for widgets which are used for editing cells. More...
#include <gtkmm/celleditable.h>
Public Member Functions | |
CellEditable (CellEditable && src) noexcept | |
CellEditable & | operator= (CellEditable && src) noexcept |
~CellEditable () noexcept override | |
GtkCellEditable * | gobj () |
Provides access to the underlying C GObject. More... | |
const GtkCellEditable * | gobj () const |
Provides access to the underlying C GObject. More... | |
void | start_editing (GdkEvent * event) |
Begins editing on a cell_editable. More... | |
void | editing_done () |
Emits the Gtk::CellEditable::signal_editing_done() signal. More... | |
void | remove_widget () |
Emits the Gtk::CellEditable::signal_remove_widget() signal. More... | |
Glib::SignalProxy< void > | signal_editing_done () |
Glib::SignalProxy< void > | signal_remove_widget () |
Glib::PropertyProxy< bool > | property_editing_canceled () |
Indicates whether editing on the cell has been canceled. More... | |
Glib::PropertyProxy_ReadOnly< bool > | property_editing_canceled () const |
Indicates whether editing on the cell has been canceled. More... | |
Static Public Member Functions | |
static void | add_interface (GType gtype_implementer) |
static GType | get_type () |
Get the GType for this class, for use with the underlying GObject type system. More... | |
Protected Member Functions | |
CellEditable () | |
You should derive from this class to use it. More... | |
virtual void | start_editing_vfunc (GdkEvent * event) |
virtual void | on_editing_done () |
This is a default handler for the signal signal_editing_done(). More... | |
virtual void | on_remove_widget () |
This is a default handler for the signal signal_remove_widget(). More... | |
Related Functions | |
(Note that these are not member functions.) | |
Glib::RefPtr< Gtk::CellEditable > | wrap (GtkCellEditable * object, bool take_copy=false) |
A Glib::wrap() method for this object. More... | |
Interface for widgets which are used for editing cells.
The CellEditable interface must be implemented for widgets to be usable when editing the contents of a TreeView cell.
|
protected |
You should derive from this class to use it.
|
noexcept |
|
overridenoexcept |
|
static |
void Gtk::CellEditable::editing_done | ( | ) |
Emits the Gtk::CellEditable::signal_editing_done() signal.
|
static |
Get the GType for this class, for use with the underlying GObject type system.
|
inline |
Provides access to the underlying C GObject.
|
inline |
Provides access to the underlying C GObject.
|
protectedvirtual |
This is a default handler for the signal signal_editing_done().
|
protectedvirtual |
This is a default handler for the signal signal_remove_widget().
|
noexcept |
Glib::PropertyProxy< bool > Gtk::CellEditable::property_editing_canceled | ( | ) |
Indicates whether editing on the cell has been canceled.
Default value: false
Glib::PropertyProxy_ReadOnly< bool > Gtk::CellEditable::property_editing_canceled | ( | ) | const |
Indicates whether editing on the cell has been canceled.
Default value: false
void Gtk::CellEditable::remove_widget | ( | ) |
Emits the Gtk::CellEditable::signal_remove_widget() signal.
Glib::SignalProxy< void > Gtk::CellEditable::signal_editing_done | ( | ) |
void on_my_editing_done()
Flags: Run Last
This signal is a sign for the cell renderer to update its value from the cell_editable.
Implementations of Gtk::CellEditable are responsible for emitting this signal when they are done editing, e.g. Gtk::Entry emits this signal when the user presses Enter. Typical things to do in a handler for signal_editing_done() are to capture the edited value, disconnect the cell_editable from signals on the Gtk::CellRenderer, etc.
Gtk::CellEditable::editing_done() is a convenience method for emitting Gtk::CellEditable::signal_editing_done().
Glib::SignalProxy< void > Gtk::CellEditable::signal_remove_widget | ( | ) |
void on_my_remove_widget()
Flags: Run Last
This signal is meant to indicate that the cell is finished editing, and the cell_editable widget is being removed and may subsequently be destroyed.
Implementations of Gtk::CellEditable are responsible for emitting this signal when they are done editing. It must be emitted after the Gtk::CellEditable::signal_editing_done() signal, to give the cell renderer a chance to update the cell's value before the widget is removed.
Gtk::CellEditable::remove_widget() is a convenience method for emitting Gtk::CellEditable::signal_remove_widget().
void Gtk::CellEditable::start_editing | ( | GdkEvent * | event | ) |
Begins editing on a cell_editable.
The Gtk::CellRenderer for the cell creates and returns a Gtk::CellEditable from Gtk::CellRenderer::start_editing(), configured for the Gtk::CellRenderer type.
start_editing() can then set up cell_editable suitably for editing a cell, e.g. making the Esc key emit Gtk::CellEditable::signal_editing_done().
Note that the cell_editable is created on-demand for the current edit; its lifetime is temporary and does not persist across other edits and/or cells.
event | The Gdk::Event that began the editing process, or nullptr if editing was initiated programmatically. |
|
protectedvirtual |
|
related |
A Glib::wrap() method for this object.
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. |