|
Open 3D Engine AzQtComponents API Reference
2205.0
O3DE is an open-source, fully-featured, high-fidelity, modular 3D engine for building games and simulations, available to every industry.
|
A widget combining a Line Edit and a Push Button. Use this widget when you want to extend a Line Edit with support for user interaction. More...
#include <BrowseEdit.h>
Inherits QFrame.
Public Types | |
| typedef LineEdit::Config | Config |
Signals | |
| void | attachedButtonTriggered () |
| Triggered when the button attached to the BrowseEdit is triggered. | |
| void | editingFinished () |
| Triggered when the user has finished editing the BrowseEdit's value. | |
| void | returnPressed () |
| Triggered when the return button is pressed while the BrowseEdit is focused. | |
| void | textChanged (const QString &text) |
| void | textEdited (const QString &text) |
| Triggered when the text value in the BrowseEdit is edited by the user. | |
| void | hasAcceptableInputChanged (bool acceptable) |
Public Member Functions | |
| BrowseEdit (QWidget *parent=nullptr) | |
| void | setAttachedButtonIcon (const QIcon &icon) |
| Sets the Icon for the button attached to this BrowseEdit. | |
| QIcon | attachedButtonIcon () const |
| Returns the Icon currently being used by the button attached to this BrowseEdit. | |
| void | setClearButtonEnabled (bool enable) |
| Enables the clear button on the Browse Edit. | |
| bool | isClearButtonEnabled () const |
| Returns true if the clear button is currently enabled on this Browse Edit. | |
| void | setLineEditReadOnly (bool readOnly) |
| Renders the BrowseEdit read-only. Double clicking on the read-only text will trigger the attached button. | |
| bool | isLineEditReadOnly () const |
| Returns true if the text of this BrowseEdit is currently read-only. | |
| void | setPlaceholderText (const QString &placeholderText) |
| QString | placeholderText () const |
| Returns the current placeholder text for the BrowseEdit. | |
| void | setText (const QString &text) |
| Sets the text value for the BrowseEdit. | |
| QString | text () const |
| Gets the text value from the BrowseEdit. | |
| void | setErrorToolTip (const QString &toolTipText) |
| QString | errorToolTip () const |
| Returns the current error message for this BrowseEdit. | |
| void | setValidator (const QValidator *validator) |
| Sets a validator on the BrowseEdit. | |
| const QValidator * | validator () const |
| Returns a pointer to the validator object on the BrowseEdit, if set. | |
| bool | hasAcceptableInput () const |
| Returns true if the current text value is accepted by the currently set validator. | |
| QLineEdit * | lineEdit () const |
| Returns a pointer to the underlying LineEdit. | |
Static Public Member Functions | |
| static Config | loadConfig (QSettings &settings) |
| static Config | defaultConfig () |
| Gets the default BrowseEdit style configuration. | |
| static void | applyDropTargetStyle (BrowseEdit *browseEdit, bool valid) |
| static void | removeDropTargetStyle (BrowseEdit *browseEdit) |
Protected Member Functions | |
| bool | eventFilter (QObject *watched, QEvent *event) override |
| bool | event (QEvent *event) override |
| void | setHasAcceptableInput (bool acceptable) |
Properties | |
| bool | acceptableInput |
| Read-only value indicating whether or not user input satisfies the inputMask condition and any validator. Default value is true. | |
Friends | |
| class | Style |
A widget combining a Line Edit and a Push Button. Use this widget when you want to extend a Line Edit with support for user interaction.
|
static |
Applies the drop target styling to the BrowseEdit.
| browseEdit | Pointer to the BrowseEdit instance to apply the style on. |
| valid | Whether the BrowseEdit is a valid drop target or not. |
|
signal |
Triggered when the text value changes from acceptable to non acceptable and vice versa, based on the current validator.
|
static |
Sets the BrowseEdit style configuration.
| settings | The settings object to load the configuration from. |
|
static |
Remove the drop target styling from the BrowseEdit.
| browseEdit | Pointer to the BrowseEdit instance to remove the style from. |
| void AzQtComponents::BrowseEdit::setErrorToolTip | ( | const QString & | toolTipText | ) |
Sets the error message shown when hovering on the warning icon when the current text value is not acceptable.
| void AzQtComponents::BrowseEdit::setPlaceholderText | ( | const QString & | placeholderText | ) |
Sets the placeholder text for the BrowseEdit. This is the message shown when the current text value is an empty string.
|
signal |
Triggered when the text value in the BrowseEdit is changed, either by the user or programmatically.
1.8.17