How can i select the currentText of a QComboBox?
Printable View
How can i select the currentText of a QComboBox?
do you mean in a lineEdit of QComboBox?
QLineEdit::selectAll
QComboBox has the following method QComboBox::lineEdit, but the comboBox must be editable. so, if it is, then only what you need it is to call QLineEdit::selectAll.
This is not helping to select the content. To explain my Question i attached 2 picture. picture 1- is the picture what i have. \
picture 2- With selection content in the find what combobox.
So my Question is how can i select the find what content through program not manually.
did you even taken a look at the docs? The last post has the answer..
Code:
combo->lineEdit()->selectAll()
that is it