1
0
mirror of https://github.com/tumic0/GPXSee.git synced 2025-01-31 09:05:14 +01:00

Fixed broken label bounding box computation

This commit is contained in:
Martin Tůma 2020-11-22 23:41:58 +01:00
parent 524a854d35
commit faf445d708

View File

@ -16,7 +16,7 @@ void AxisLabelItem::setLabel(const QString& label, const QString &units)
prepareGeometryChange();
QFontMetrics fm(_font);
_label = QString("%1 [%2]").arg(label, units.isEmpty() ? "-" : units);
_labelBB = fm.tightBoundingRect(label);
_labelBB = fm.tightBoundingRect(_label);
updateBoundingRect();
update();
}