diff --git a/sources/qetapp.cpp b/sources/qetapp.cpp index c73dfbcb3..dbfa53528 100644 --- a/sources/qetapp.cpp +++ b/sources/qetapp.cpp @@ -2044,21 +2044,21 @@ void QETApp::initConfiguration() QDir config_dir(QETApp::configDir()); if (!config_dir.exists()) config_dir.mkpath(QETApp::configDir()); - QDir custom_elements_dir(QETApp::customElementsDir()); - if (!custom_elements_dir.exists()) - custom_elements_dir.mkpath(QETApp::customElementsDir()); + QDir custom_elements_dir(QETApp::customElementsDir()); + if (!custom_elements_dir.exists()) + custom_elements_dir.mkpath(QETApp::customElementsDir()); - QDir company_elements_dir(QETApp::companyElementsDir()); - if (!company_elements_dir.exists()) - company_elements_dir.mkpath(QETApp::companyElementsDir()); + QDir company_elements_dir(QETApp::companyElementsDir()); + if (!company_elements_dir.exists()) + company_elements_dir.mkpath(QETApp::companyElementsDir()); - QDir company_tbt_dir(QETApp::companyTitleBlockTemplatesDir()); - if (!company_tbt_dir.exists()) - company_tbt_dir.mkpath(QETApp::companyTitleBlockTemplatesDir()); + QDir company_tbt_dir(QETApp::companyTitleBlockTemplatesDir()); + if (!company_tbt_dir.exists()) + company_tbt_dir.mkpath(QETApp::companyTitleBlockTemplatesDir()); - QDir custom_tbt_dir(QETApp::customTitleBlockTemplatesDir()); - if (!custom_tbt_dir.exists()) - custom_tbt_dir.mkpath(QETApp::customTitleBlockTemplatesDir()); + QDir custom_tbt_dir(QETApp::customTitleBlockTemplatesDir()); + if (!custom_tbt_dir.exists()) + custom_tbt_dir.mkpath(QETApp::customTitleBlockTemplatesDir()); /* recent files * note: diff --git a/sources/qetgraphicsitem/qetshapeitem.cpp b/sources/qetgraphicsitem/qetshapeitem.cpp index eaafe7336..fee4b3b5f 100644 --- a/sources/qetgraphicsitem/qetshapeitem.cpp +++ b/sources/qetgraphicsitem/qetshapeitem.cpp @@ -952,31 +952,31 @@ bool QetShapeItem::toDXF(const QString &filepath,const QPen &pen) switch (m_shapeType) { case Line: - Createdxf::drawLine(filepath, + Createdxf::drawLine(filepath, QLineF( mapToScene(m_P1), mapToScene(m_P2)), Createdxf::dxfColor(pen)); - return true; + return true; case Rectangle: - Createdxf::drawRectangle(filepath, - QRectF(mapToScene(m_P1), + Createdxf::drawRectangle(filepath, + QRectF(mapToScene(m_P1), mapToScene(m_P2)).normalized(), Createdxf::dxfColor(pen)); - return true; + return true; case Ellipse: - Createdxf::drawEllipse(filepath, - QRectF(mapToScene(m_P1), + Createdxf::drawEllipse(filepath, + QRectF(mapToScene(m_P1), mapToScene(m_P2)).normalized(), Createdxf::dxfColor(pen)); - return true; - case Polygon: - 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; + return true; + case Polygon: + 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; } }