mirror of
https://github.com/subsurface/subsurface.git
synced 2025-02-19 22:16:15 +00:00
Correct collors for the DivePlanner background.
Use the correct colors for the Background on the Dive Plan, same as on the Profile. Signed-off-by: Tomaz Canabrava <tcanabrava@kde.org>
This commit is contained in:
parent
b07429ff8b
commit
94c2e5dc18
1 changed files with 5 additions and 5 deletions
|
@ -242,16 +242,16 @@ void DivePlannerGraphics::createDecoStops()
|
||||||
|
|
||||||
diveBg->setPolygon(poly);
|
diveBg->setPolygon(poly);
|
||||||
QRectF b = poly.boundingRect();
|
QRectF b = poly.boundingRect();
|
||||||
QLinearGradient linearGrad(
|
QLinearGradient pat(
|
||||||
b.x(),
|
b.x(),
|
||||||
b.y(),
|
b.y(),
|
||||||
b.x(),
|
b.x(),
|
||||||
b.height() + b.y()
|
b.height() + b.y()
|
||||||
);
|
);
|
||||||
|
|
||||||
linearGrad.setColorAt(0, Qt::green);
|
pat.setColorAt(1, profile_color[DEPTH_BOTTOM].first());
|
||||||
linearGrad.setColorAt(1, Qt::white);
|
pat.setColorAt(0, profile_color[DEPTH_TOP].first());
|
||||||
diveBg->setBrush(linearGrad);
|
diveBg->setBrush(pat);
|
||||||
|
|
||||||
deleteTemporaryDivePlan(diveplan.dp);
|
deleteTemporaryDivePlan(diveplan.dp);
|
||||||
}
|
}
|
||||||
|
@ -409,7 +409,7 @@ void Ruler::updateTicks()
|
||||||
double steps = (max - min) / interval;
|
double steps = (max - min) / interval;
|
||||||
double stepSize = (m.x2() - m.x1()) / steps;
|
double stepSize = (m.x2() - m.x1()) / steps;
|
||||||
qreal pos;
|
qreal pos;
|
||||||
for (pos = m.x1(); pos < m.x2(); pos += stepSize) {
|
for (qreal pos = m.x1(); pos < m.x2(); pos += stepSize) {
|
||||||
ticks.push_back(new QGraphicsLineItem(pos, m.y1(), pos, m.y1() + tickSize, this));
|
ticks.push_back(new QGraphicsLineItem(pos, m.y1(), pos, m.y1() + tickSize, this));
|
||||||
}
|
}
|
||||||
ticks.push_back(new QGraphicsLineItem(pos, m.y1(), pos, m.y1() + tickSize, this));
|
ticks.push_back(new QGraphicsLineItem(pos, m.y1(), pos, m.y1() + tickSize, this));
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue