mirror of
https://github.com/subsurface/subsurface.git
synced 2024-11-28 05:00:20 +00:00
Profile2: fix widths on some lines for Qt5
Qt5 uses different widths for some of the poly. lines in the profile. Setting an explicit value fixes that. Tested-by: Anton Lundin <glance@acc.umu.se> Signed-off-by: Lubomir I. Ivanov <neolit123@gmail.com> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
parent
fdf6f3cd4e
commit
71f2fd91b5
2 changed files with 4 additions and 2 deletions
|
@ -668,11 +668,12 @@ void PartialPressureGasItem::modelDataChanged(const QModelIndex &topLeft, const
|
|||
|
||||
void PartialPressureGasItem::paint(QPainter *painter, const QStyleOptionGraphicsItem *option, QWidget *widget)
|
||||
{
|
||||
painter->setPen(normalColor);
|
||||
const qreal pWidth = 0.0;
|
||||
painter->setPen(QPen(normalColor, pWidth));
|
||||
painter->drawPolyline(polygon());
|
||||
|
||||
QPolygonF poly;
|
||||
painter->setPen(alertColor);
|
||||
painter->setPen(QPen(alertColor, pWidth));
|
||||
Q_FOREACH(const QPolygonF & poly, alertPolygons)
|
||||
painter->drawPolyline(poly);
|
||||
|
||||
|
|
|
@ -77,6 +77,7 @@ RulerItem2::RulerItem2() : source(new RulerNodeItem2()),
|
|||
textItem->setFlag(QGraphicsItem::ItemIgnoresTransformations);
|
||||
textItemBack->setBrush(QColor(0xff, 0xff, 0xff, 190));
|
||||
textItemBack->setPen(QColor(Qt::white));
|
||||
setPen(QPen(QColor(Qt::black), 0.0));
|
||||
}
|
||||
|
||||
void RulerItem2::recalculate()
|
||||
|
|
Loading…
Reference in a new issue