Unsolved How to style a disabled item in a QComboBox ? (qss)
-
I used this code to disable an item inside a combobox : https://stackoverflow.com/questions/38915001/disable-specific-items-in-qcombobox
I can disable specific items in QComboBox (it's ok)And I would like a visual feedback. I would like to put the text of the disabled item in red.
I tried this code but it doesn't nothing.
QComboBox::item:!enabled { color:red; }
I think that it's somewhere in the drop-down. But this code doesn't work also :
QComboBox::drop-down:item:!enabled { color:red; }
-
QComboBox QAbstractItemView::item:!enabled { color:red; }
-
Try my code. It will style the disabled combobox items.
QComboBox QAbstractItemView::disabled { color: #FF0000; }