Qt Utilities
5.12.0
Common Qt related C++ classes and routines used by my applications such as dialogs, widgets and models
|
A QPlainTextEdit with an embedded button for clearing its contents. More...
#include <clearplaintextedit.h>
Public Member Functions | |
ClearPlainTextEdit (QWidget *parent=nullptr) | |
Constructs a clear plain text edit. More... | |
~ClearPlainTextEdit () override | |
Destroys the clear plain text edit. More... | |
bool | isCleared () const override |
Returns whether the related widget is cleared. More... | |
![]() | |
ButtonOverlay (QWidget *widget) | |
Constructs a button overlay for the specified widget. More... | |
virtual | ~ButtonOverlay () |
Destroys the button overlay. More... | |
QHBoxLayout * | buttonLayout () |
Returns the layout manager holding the buttons. More... | |
bool | isClearButtonEnabled () const |
Returns whether the clear button is enabled. More... | |
void | setClearButtonEnabled (bool enabled) |
Sets whether the clear button is enabled. More... | |
bool | isInfoButtonEnabled () const |
Returns whether the info button is enabled. More... | |
void | enableInfoButton (const QPixmap &pixmap, const QString &infoText) |
Shows an info button with the specified pixmap and infoText. More... | |
void | disableInfoButton () |
Hides an info button if one is shown. More... | |
void | addCustomButton (QWidget *button) |
Adds a custom button. More... | |
void | insertCustomButton (int index, QWidget *button) |
Inserts a custom button at the specified index. More... | |
void | removeCustomButton (QWidget *button) |
Removes the specified custom button. More... | |
Additional Inherited Members | |
![]() | |
void | updateClearButtonVisibility (bool visible) |
Updates the visibility of the clear button. More... | |
virtual void | handleClearButtonClicked () |
Clears the related widget. More... | |
A QPlainTextEdit with an embedded button for clearing its contents.
Definition at line 10 of file clearplaintextedit.h.
|
explicit |
Constructs a clear plain text edit.
Definition at line 18 of file clearplaintextedit.cpp.
|
override |
Destroys the clear plain text edit.
Definition at line 34 of file clearplaintextedit.cpp.
|
overridevirtual |
Returns whether the related widget is cleared.
This method is meant to be implemented when subclassing.
Reimplemented from Widgets::ButtonOverlay.
Definition at line 59 of file clearplaintextedit.cpp.