Editable Label. More...
#include <EditableLabel.hh>
Inherits QWidget.
Public Member Functions | |
EditableLabel (const std::string &_label, QWidget *_parent=nullptr) | |
Constructor. More... | |
~EditableLabel () | |
Destructor. More... | |
std::string | Text () const |
Get the string of this label. More... | |
Protected Member Functions | |
virtual void | keyPressEvent (QKeyEvent *_event) |
Qt key press event. More... | |
virtual void | mouseDoubleClickEvent (QMouseEvent *_event) |
Qt mouse double click event. More... | |
Editable Label.
The widget toggles between a QLabel and QLineEdit to support edits to the label text.
EditableLabel | ( | const std::string & | _label, |
QWidget * | _parent = nullptr |
||
) |
Constructor.
[in] | _label | Label text. |
[in] | _parent | Parent widget. |
~EditableLabel | ( | ) |
Destructor.
|
protectedvirtual |
Qt key press event.
[in] | _event | Qt key event |
|
protectedvirtual |
Qt mouse double click event.
[in] | _event | Qt mouse event |
std::string Text | ( | ) | const |
Get the string of this label.