Solved How to make input field with list under it contain suggestions?
as you can see from this photo I'm trying to make a input field with suggestions under it in a list
can anyone know how to do it
Hi and welcome
You can use QCompleter
here it uses files but list can be anything.
@mrjj is there a way to use QCompleter in form design
nope as its not visual.
But you can assign it to Edit you have placed on form. (UI)
so almost yes.
All it takes is
(after setupUI()) QStringList wordList; wordList << "alpha" << "omega" << "omicron" << "zeta"; QCompleter *completer = new QCompleter(wordList, this); completer->setCaseSensitivity(Qt::CaseInsensitive); ui->lineEdit->setCompleter(completer);
@mrjj thanks a lot