forked from qt-creator/qt-creator
Fixes: Toolbar cosmetic problem
RevBy: b_lindeijer
Details:
This resolves the problem with missing top-borders on
the find toolbar.
(cherry picked from commit e5c845fcc7)
This commit is contained in:
committed by
Thorbjørn Lindeijer
parent
932845fc36
commit
3b7c35fa9b
@@ -871,10 +871,11 @@ void ManhattanStyle::drawControl(ControlElement element, const QStyleOption *opt
|
||||
painter->setPen(StyleHelper::borderColor());
|
||||
|
||||
if (horizontal) {
|
||||
// Note: This is a hack to determine if we are the topmost
|
||||
// toolbar and menu bar should draw the outline
|
||||
// Note: This is a hack to determine if the
|
||||
// toolbar should draw the top or bottom outline
|
||||
// (needed for the find toolbar for instance)
|
||||
QColor lighter(255, 255, 255, 40);
|
||||
if (widget->mapToParent(rect.topLeft()).y()) {
|
||||
if (widget && widget->property("topBorder").toBool()) {
|
||||
p->drawLine(rect.topLeft(), rect.topRight());
|
||||
p->setPen(lighter);
|
||||
p->drawLine(rect.topLeft() + QPoint(0, 1), rect.topRight() + QPoint(0, 1));
|
||||
|
||||
Reference in New Issue
Block a user