Hi everyone.
I'm using Qt4 on Windows and I'm encountering troubles with the buttons colors.
Two questions I have:
1) Even changing the QPalette::Button and QPalette::ButtonText colors of a QPushButton palette, why just the text gets changed and not the background? Do palettes support multiple changes? Here follows the piece of code which changes the palette:
pal.
setColor(QPalette::ButtonText, Qt
::white);
pal.
setColor(QPalette::Button, Qt
::black);
ui.cmdsounddod->setPalette(pal);
QPalette pal;
pal.setColor(QPalette::ButtonText, Qt::white);
pal.setColor(QPalette::Button, Qt::black);
ui.cmdsounddod->setPalette(pal);
To copy to clipboard, switch view to plain text mode
2) To Qt developers: was this palette approach needed? 
Well, I mean, in Qt3 to change a color needed a call to
uiobject
->setBackgroundColor
(QColor)
uiobject->setBackgroundColor(QColor)
To copy to clipboard, switch view to plain text mode
and now it needs to pass through the palette that I find a bit complex... 
I wouldn't be surprised if I miss a quicker way to change a ui object color... 
Thank you in advance,
any help is appreciated
Bookmarks