mirror of
https://github.com/tumic0/GPXSee.git
synced 2024-11-28 13:41:16 +01:00
Added missing error handling
This commit is contained in:
parent
17b3602fda
commit
b59112f74e
@ -100,6 +100,8 @@ static QPainterPath textPath(const QPolygonF &path, qreal textWidth,
|
|||||||
qreal charWidth, const QRectF &tileRect)
|
qreal charWidth, const QRectF &tileRect)
|
||||||
{
|
{
|
||||||
QList<QLineF> lines(lineString(path, tileRect));
|
QList<QLineF> lines(lineString(path, tileRect));
|
||||||
|
if (lines.isEmpty())
|
||||||
|
return QPainterPath();
|
||||||
qreal length = 0;
|
qreal length = 0;
|
||||||
qreal angle = lines.first().angle();
|
qreal angle = lines.first().angle();
|
||||||
int last = 0;
|
int last = 0;
|
||||||
|
Loading…
Reference in New Issue
Block a user