Qt - How to use rich text in QComboBox?

I am trying to use rich text in a QComboBox, but it does not support it. Maybe I should write a subclass? But I'm not sure what I will need to override, since I had never done anything like this before. Please help. Thanks!

+4
source share
1 answer

I think the custom delegate class is the answer. The solution is to simply replace the standard drawing procedure with your own (using, for example, QLabel). Here was a similar question: QListView / QListWidget with custom items and custom item widgets

+1
source

Source: https://habr.com/ru/post/1304558/


All Articles