Allow for open polygons (ie polylines) when saving as dxf

This commit is contained in:
David Varley
2022-08-13 11:57:29 +10:00
parent e9931511de
commit af5d5e0aa3
2 changed files with 8 additions and 2 deletions

View File

@@ -970,7 +970,10 @@ bool QetShapeItem::toDXF(const QString &filepath,const QPen &pen)
Createdxf::dxfColor(pen));
return true;
case Polygon:
Createdxf::drawPolygon(filepath,m_polygon,Createdxf::dxfColor(pen));
if(m_polygon.isClosed())
Createdxf::drawPolygon(filepath,m_polygon,Createdxf::dxfColor(pen));
else
Createdxf::drawPolyline(filepath,m_polygon,Createdxf::dxfColor(pen));
return true;
default:
return false;