Use a custom details button

* Use a custom details button rendering.
   This should work better on the mac ans looks nicer, too:-)

Reviewed-by: Roberto Raggi
This commit is contained in:
Tobias Hunger
2009-12-01 17:44:16 +01:00
parent e9a20d33c7
commit 491527ab06
3 changed files with 78 additions and 35 deletions

View File

@@ -38,7 +38,7 @@ DetailsWidget::DetailsWidget(QWidget *parent) :
m_grid->setContentsMargins(0, 0, 0, 0);
m_grid->setSpacing(0);
m_grid->addWidget(m_summaryLabel, 0, 1);
m_grid->addWidget(m_detailsButton, 0, 2, 1, 1, Qt::AlignCenter);
m_grid->addWidget(m_detailsButton, 0, 2);
m_detailsButton->setEnabled(false);
@@ -179,8 +179,8 @@ QPixmap DetailsWidget::cacheBackground(const QSize &size, bool expanded)
p.drawRect(0, 0, size.width() - 1, size.height() - 1);
if (expanded) {
p.drawLine(0, m_summaryLabel->height(),
size.width(), m_summaryLabel->height());
p.drawLine(0, m_summaryLabel->height() - 1,
m_summaryLabel->width(), m_summaryLabel->height() - 1);
}
return pixmap;