Search code examples
pythonqtqcombobox

QComboBox: same words with different cases are seen as duplicates


I have a QComboBox and say I type the word "info" in the box, followed by "INFO".
Why doesn't it remember both as 2 distinct words and instead convert "INFO" to "info"?

How can I go about solving this issue so that both words would end up in the list. Also the back-end is in python.

Note: I would prefer a solution without setDuplicatesEnabled.
I read the documentation and searched the web but with no luck and I cannot figure this one out. Most answers on SO were outdated(5+ years )


Solution

  • The easiest way - to use setAutoCompletion(false) on your QComboBox.