TankBar: make outline zero-width

In some circumstances Qt will draw a really thick border around
rectangles. This explicitly makes the border of the tank bar thin.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
Dirk Hohndel 2014-08-18 11:47:18 -05:00
parent b1cd536e1c
commit 88fe28636e

View file

@ -4,6 +4,7 @@
#include "profile.h"
#include <QGradient>
#include <QDebug>
#include <QPen>
TankItem::TankItem(QObject *parent) :
QGraphicsRectItem(),
@ -50,6 +51,7 @@ void TankItem::createBar(qreal x, qreal w, struct gasmix *gas)
rect->setBrush(trimix);
else
rect->setBrush(nitrox);
rect->setPen(QPen(QBrush(), 0.0)); // get rid of the thick line around the rectangle
rects.push_back(rect);
DiveTextItem *label = new DiveTextItem(rect);
label->setText(gasname(gas));