fix indention to get rid of warnings: "if/else does not guard"

This commit is contained in:
plc-user
2024-04-07 14:46:40 +02:00
parent f343395da0
commit f4c880dc9f
2 changed files with 28 additions and 28 deletions

View File

@@ -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:

View File

@@ -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;
}
}