Make new header color green
Status: Beta
Brought to you by:
bauno
The following code, sent by J. Fourniez, makes new
headers in the headerlist dark green
void BHListViewItem::paintCell( QPainter * p, const
QColorGroup & cg,
int column, int width, int alignment )
{
QColorGroup _cg( cg );
_cg.setColor( QColorGroup::Text, lineColor);
KListViewItem::paintCell( p, _cg, column, width,
alignment );
if (status==BinHeader::bh_new)
{
setPixmap(Subj_Col, BarIcon("icon_article_new",
KIcon::SizeSmall));
lineColor=Qt::darkGreen;
}
else if (status==BinHeader::bh_read)
setPixmap(Subj_Col, BarIcon("icon_article_read",
KIcon::SizeSmall));
else if (status==BinHeader::bh_downloaded)
setPixmap(Subj_Col, BarIcon("icon_binary",
KIcon::SizeSmall));
}