[Qt-interest] QPalette on PushButton
chandrasekar wagmare
sekarwagmare at gmail.com
Fri Jan 30 13:49:21 CET 2009
hi friends,
i try to display different color with respect to the input ..
so to set the color value i use three variable rd , gr , bl and i use it as
QColor(rd,gr,bl)
using i program as
QPalette p;
p.setColor(QPalette::Background,QColor(rd,gr,bl));
Button->setPalette(p);
1Button->setPalette(p);
2Button->setPalette(p);
cButton->setPalette(p);
1Label->setPalette(p);
2Label->setPalette(p);
3Label->setPalette(p);
4Label->setPalette(p);
here all the labels are displaying the color but
pushButtons are not displaying the background colors ... why?
i enabled the autofillBackground() also ... if it is not possible then there
is any other way to change the color effect according to input ie using a
variable for setting color ... ?
please help
thanks in advance
--
CHANDRU
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.qt-project.org/pipermail/qt-interest-old/attachments/20090130/ed93ee2a/attachment.html
More information about the Qt-interest-old
mailing list