Trait gtk4::prelude::CellEditableExt
source · pub trait CellEditableExt: 'static {
// Required methods
fn editing_done(&self);
fn remove_widget(&self);
fn is_editing_canceled(&self) -> bool;
fn set_editing_canceled(&self, editing_canceled: bool);
fn connect_editing_done<F: Fn(&Self) + 'static>(
&self,
f: F
) -> SignalHandlerId;
fn connect_remove_widget<F: Fn(&Self) + 'static>(
&self,
f: F
) -> SignalHandlerId;
fn connect_editing_canceled_notify<F: Fn(&Self) + 'static>(
&self,
f: F
) -> SignalHandlerId;
}
Expand description
Trait containing all CellEditable
methods.
Implementors
Required Methods§
sourcefn editing_done(&self)
fn editing_done(&self)
Emits the GtkCellEditable::editing-done
signal.
sourcefn remove_widget(&self)
fn remove_widget(&self)
Emits the GtkCellEditable::remove-widget
signal.
sourcefn is_editing_canceled(&self) -> bool
fn is_editing_canceled(&self) -> bool
Indicates whether editing on the cell has been canceled.
sourcefn set_editing_canceled(&self, editing_canceled: bool)
fn set_editing_canceled(&self, editing_canceled: bool)
Indicates whether editing on the cell has been canceled.
sourcefn connect_editing_done<F: Fn(&Self) + 'static>(&self, f: F) -> SignalHandlerId
fn connect_editing_done<F: Fn(&Self) + 'static>(&self, f: F) -> SignalHandlerId
This signal is a sign for the cell renderer to update its value from the @cell_editable.
Implementations of CellEditable
are responsible for
emitting this signal when they are done editing, e.g.
Entry
emits this signal when the user presses Enter. Typical things to
do in a handler for ::editing-done are to capture the edited value,
disconnect the @cell_editable from signals on the CellRenderer
, etc.
gtk_cell_editable_editing_done() is a convenience method
for emitting GtkCellEditable::editing-done
.
sourcefn connect_remove_widget<F: Fn(&Self) + 'static>(&self, f: F) -> SignalHandlerId
fn connect_remove_widget<F: Fn(&Self) + 'static>(&self, f: F) -> SignalHandlerId
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 CellEditable
are responsible for
emitting this signal when they are done editing. It must
be emitted after the GtkCellEditable::editing-done
signal,
to give the cell renderer a chance to update the cell’s value
before the widget is removed.
gtk_cell_editable_remove_widget() is a convenience method
for emitting GtkCellEditable::remove-widget
.