Edit
Edit
Edit controls collect single-line or multi-line user input.
Inheritance
Edit widgets follow the WidgetKit base widget model and add text editing, placeholder, focus, disabled, and serialization behavior.
QWidget
└─ QLineEdit
└─ UIGQLineEdit + IUIGQWidgetBase
Common APIs
| Method | Description | Parameters | Return |
|---|---|---|---|
setText(const QString& text) |
Sets current text. | text: edit content. |
void |
text() const |
Returns current text. | None. | QString |
setPlaceholderText(const QString& text) |
Sets placeholder text. | text: placeholder content. |
void |
setThemeName(const QString& themeName) |
Applies themed borders, background, and text colors. | themeName: theme configuration name. |
void |
setReadOnly(bool readOnly) |
Switches between editable and read-only behavior. | readOnly: whether editing is disabled. |
void |
Theme and Behavior
Use the control API for current text, placeholder, password mode, hotkey mode, margins, and read-only behavior. Keep normal, hover, focus, disabled, and placeholder appearance in the theme layer.
Use validation outside the control unless the project defines a shared validation component.