Qt-interest Archive, March 2007
Unable to set back ground color for line edit in and filed names for table qte
Message 1 in thread
Hi,
Is there any way to set background color for line edit in qte.
I tried with lineedit->setpallette()
with base= white and background = blue but no success.
is it possible to set filed names in a table
I want a table like this
SNO NAME ID DISCRIPTION
1.
2.
--
[ signature omitted ]
Message 2 in thread
Please post the exact code. I have done this quite successfully using palettes. For example:
QLineEdit *line = new QLineEdit(parent);
QPalette p = line->palette();
p.setColor(QtPalette::Base, Qt::White);
p.setColor(QtPalette::Text, Qt::Blue);
line->setPalette(p);
This should set the foreground to blue and the background to white. Alternatively you could create a new palette instead of using line->palette(). You can also set the colors for the disabled/active/inactive state.
I am assuming Qt4 here.
HTH,
Susan
----- Original Message ----
From: venugopal reddy <venu.forum@xxxxxxxxx>
To: qt-interest@xxxxxxxxxxxxx
Sent: Tuesday, March 13, 2007 9:02:18 AM
Subject: Unable to set back ground color for line edit in and filed names for table qte
Hi,
Is there any way to set background color for line edit in qte.
I tried with lineedit->setpallette()
with base= white and background = blue but no success.
is it possible to set filed names in a table
I want a table like this
SNO NAME ID DISCRIPTION
1.
2.
--
[ signature omitted ]