diff options
author | Christian Ehrlicher <ch.ehrlicher@gmx.de> | 2018-01-17 12:01:44 +0100 |
---|---|---|
committer | Christian Ehrlicher <ch.ehrlicher@gmx.de> | 2018-01-18 18:01:39 +0000 |
commit | e6fa35ff14ed8f532564129cf4fb7f9bfc64ce8f (patch) | |
tree | 0d0d367fabad87a9f3d52dea43b082b8ac1bfa1d /src/widgets | |
parent | 4944f4d57c814390bfcb4efb3d0e9c9805aab74d (diff) |
Sync QItemDelegate::doLayout with QCommonStylePrivate::viewItemLayout
QItemDelegate::doLayout added a margin after the checkbox which is not
done within QCommonStylePrivate::viewItemLayout. This created a small
but visual difference between using QItemDelegate or QStyledItemDelegate.
The additional margin was removed from viewItemLayout somehwere between
4.4 and 4.5 so it was intentional.
Change-Id: I2fc3f287fe8b181355edeebec9626c49d85fe74d
Reviewed-by: Thorbjørn Lund Martsum <tmartsum@gmail.com>
Diffstat (limited to 'src/widgets')
-rw-r--r-- | src/widgets/itemviews/qitemdelegate.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/widgets/itemviews/qitemdelegate.cpp b/src/widgets/itemviews/qitemdelegate.cpp index e1089e3158..1ff51f9be2 100644 --- a/src/widgets/itemviews/qitemdelegate.cpp +++ b/src/widgets/itemviews/qitemdelegate.cpp @@ -845,7 +845,7 @@ void QItemDelegate::doLayout(const QStyleOptionViewItem &option, if (option.direction == Qt::RightToLeft) { check.setRect(x + w - cw, y, cw, h); } else { - check.setRect(x + checkMargin, y, cw, h); + check.setRect(x, y, cw, h); } } |