forked from qt-creator/qt-creator
Bookmarks: Fix a HighDPI off-by-1 issue in the Bookmarks view
Change-Id: I172d887234ac60ef8eba6c695582cfe41a45d9e9 Reviewed-by: Robert Loehning <robert.loehning@qt.io> Reviewed-by: Eike Ziller <eike.ziller@qt.io>
This commit is contained in:
@@ -202,8 +202,9 @@ void BookmarkDelegate::paint(QPainter *painter, const QStyleOptionViewItem &opti
|
||||
painter->drawText(6, opt.rect.top() + fm.ascent() + fm.height() + 6, lineText);
|
||||
|
||||
// Separator lines
|
||||
const QRectF innerRect = QRectF(opt.rect).adjusted(0.5, 0.5, -0.5, -0.5);
|
||||
painter->setPen(QColor::fromRgb(150,150,150));
|
||||
painter->drawLine(0, opt.rect.bottom(), opt.rect.right(), opt.rect.bottom());
|
||||
painter->drawLine(innerRect.bottomLeft(), innerRect.bottomRight());
|
||||
painter->restore();
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user