mirror of
https://github.com/qelectrotech/qelectrotech-source-mirror.git
synced 2025-12-18 05:00:33 +01:00
DXF export : fix some double items in dxf file, thanks to Gabberworld for this patch
git-svn-id: svn+ssh://svn.tuxfamily.org/svnroot/qet/qet/trunk@5230 bfdf4180-ca20-0410-9c96-a3a8aa849046
This commit is contained in:
@@ -398,6 +398,7 @@ void ExportDialog::generateSvg(Diagram *diagram, int width, int height, bool kee
|
|||||||
@param io_device Peripherique de sortie pour le code DXF (souvent : un fichier)
|
@param io_device Peripherique de sortie pour le code DXF (souvent : un fichier)
|
||||||
*/
|
*/
|
||||||
void ExportDialog::generateDxf(Diagram *diagram, int width, int height, bool keep_aspect_ratio, QString &file_path) {
|
void ExportDialog::generateDxf(Diagram *diagram, int width, int height, bool keep_aspect_ratio, QString &file_path) {
|
||||||
|
saveReloadDiagramParameters(diagram, true);
|
||||||
|
|
||||||
project_ -> setFilePath(file_path);
|
project_ -> setFilePath(file_path);
|
||||||
|
|
||||||
@@ -410,7 +411,9 @@ void ExportDialog::generateDxf(Diagram *diagram, int width, int height, bool kee
|
|||||||
Createdxf::dxfBegin(file_path);
|
Createdxf::dxfBegin(file_path);
|
||||||
|
|
||||||
//Add project elements (lines, rectangles, circles, texts) to dxf file
|
//Add project elements (lines, rectangles, circles, texts) to dxf file
|
||||||
|
if (epw -> exportProperties().draw_border) {
|
||||||
Createdxf::drawRectangle(file_path, 0, 0, double(width)*Createdxf::xScale, double(height)*Createdxf::yScale, 0);
|
Createdxf::drawRectangle(file_path, 0, 0, double(width)*Createdxf::xScale, double(height)*Createdxf::yScale, 0);
|
||||||
|
}
|
||||||
diagram -> border_and_titleblock.drawDxf(width, height, keep_aspect_ratio, file_path, 0);
|
diagram -> border_and_titleblock.drawDxf(width, height, keep_aspect_ratio, file_path, 0);
|
||||||
|
|
||||||
// Build the lists of elements.
|
// Build the lists of elements.
|
||||||
@@ -677,6 +680,8 @@ void ExportDialog::generateDxf(Diagram *diagram, int width, int height, bool kee
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
Createdxf::dxfEnd(file_path);
|
Createdxf::dxfEnd(file_path);
|
||||||
|
|
||||||
|
saveReloadDiagramParameters(diagram, false);
|
||||||
}
|
}
|
||||||
|
|
||||||
void ExportDialog::fillRow(QString file_path, const QRectF &row_rect, QString author, QString title,
|
void ExportDialog::fillRow(QString file_path, const QRectF &row_rect, QString author, QString title,
|
||||||
|
|||||||
Reference in New Issue
Block a user