Fixed crash. If we have no points in the seam allowence path just don't show

him.

--HG--
branch : develop
This commit is contained in:
Roman Telezhynskyi 2015-03-28 14:26:49 +02:00
parent f97a077dcd
commit b104f0dfa5

View File

@ -461,6 +461,8 @@ QPainterPath VDetail::ContourPath(const VContainer *data) const
// seam allowence // seam allowence
if (getSeamAllowance() == true) if (getSeamAllowance() == true)
{
if (not pointsEkv.isEmpty())
{ {
QPainterPath ekv; QPainterPath ekv;
ekv.moveTo(pointsEkv.at(0)); ekv.moveTo(pointsEkv.at(0));
@ -472,6 +474,7 @@ QPainterPath VDetail::ContourPath(const VContainer *data) const
path.addPath(ekv); path.addPath(ekv);
path.setFillRule(Qt::WindingFill); path.setFillRule(Qt::WindingFill);
} }
}
return path; return path;
} }