Package: gtk

Class gtk:editable-label

Superclasses

Documented Subclasses

None

Direct Slots

editing
The editing property of type :boolean (Read)
The property is true while the widget is in edit mode.
Default value: false

Details

The gtk:editable-label widget is a gtk:label widget that allows users to edit the text by switching the widget to an "edit mode".

Figure: GtkEditableLabel

The gtk:editable-label widget does not have API of its own, but it implements the gtk:editable interface.

The default bindings for activating the edit mode is to click or press the Enter key. The default bindings for leaving the edit mode are the Enter key, to save the results, or the Escape key, to cancel the editing.

CSS Nodes

editablelabel[.editing]
╰── stack
    ├── label
    ╰── text    
The gtk:editable-label implementation has a main node with the name editablelabel. When the text entry is in editing mode, it gets the .editing style class. For all the subnodes added to the text node in various situations, see the gtk:text documentation.

Action Details

The "editing.stop" action
Switch the widget out of editing mode. If commit is true, then the results of the editing are taken as the new value of the text property. The default binding for this action is the Escape key. This action is disabled when the editing property is false.
commit
The boolean whether to make changes permanent.
The "editing.start" action
Switch the widget into editing mode, so that the user can make changes to the text. The default bindings for this action are clicking on the widget and the Enter key. This action is disabled when the editing property is false.
 

Returned by

Slot Access Functions

Inherited Slot Access Functions

See also

2024-5-23