Question

I would to set the font style of first item on a QComboBox. I'm using the Qt framework. How can I do that?

Was it helpful?

Solution

Problem solved.

combo.setItemData(rowIndex, QVariant(myCustomFont), Qt.FontRole)

I'm using PyQt

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top