Quote Originally Posted by Giga View Post
Use QPalette instead.
1. The title of this post says that he want to use QStyle.
Customizing a dialogs background with QStyle
2. Qt Docs says:
For example, the following style sheet specifies that all QLineEdits should use yellow as their background color, and all QCheckBoxes should use red as the text color:

QLineEdit { background: yellow }
QCheckBox { color: red }
For this kind of customization, style sheets are much more powerful than QPalette.