Mac: Update PE_IndicatorToolBarHandle drawing.
Smaller, rounder, darker toolbar handles. Works especially well in unified toolbar mode. Task-number: QTBUG-34411 Change-Id: I41eafdf0bb1dbbb4ed96d7bd799eb6f53bccbf7d Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@digia.com>bb10
parent
cd5ae8fb21
commit
459ad9e018
|
|
@ -3008,23 +3008,19 @@ void QMacStyle::drawPrimitive(PrimitiveElement pe, const QStyleOption *opt, QPai
|
|||
if (opt->state & State_Horizontal) {
|
||||
while (y < opt->rect.height() - RectHeight - 5) {
|
||||
path.moveTo(x, y);
|
||||
path.addRect(x, y, RectHeight, RectHeight);
|
||||
path.addEllipse(x, y, RectHeight, RectHeight);
|
||||
y += 6;
|
||||
}
|
||||
} else {
|
||||
while (x < opt->rect.width() - RectHeight - 5) {
|
||||
path.moveTo(x, y);
|
||||
path.addRect(x, y, RectHeight, RectHeight);
|
||||
path.addEllipse(x, y, RectHeight, RectHeight);
|
||||
x += 6;
|
||||
}
|
||||
}
|
||||
p->setPen(Qt::NoPen);
|
||||
QColor dark = opt->palette.dark().color();
|
||||
dark.setAlphaF(0.75);
|
||||
QColor light = opt->palette.light().color();
|
||||
light.setAlphaF(0.6);
|
||||
p->fillPath(path, light);
|
||||
p->translate(1, 1);
|
||||
QColor dark = opt->palette.dark().color().darker();
|
||||
dark.setAlphaF(0.50);
|
||||
p->fillPath(path, dark);
|
||||
p->restore();
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue