From a6976fd1ee263f5f9f38f21044b097fff268df25 Mon Sep 17 00:00:00 2001 From: Roman Telezhynskyi Date: Thu, 20 Jul 2017 19:14:19 +0300 Subject: [PATCH] Fix details position if export from Detail mode. red #391. --HG-- branch : develop --- src/app/valentina/mainwindowsnogui.cpp | 9 +++------ src/libs/vdxf/vdxfengine.cpp | 2 -- 2 files changed, 3 insertions(+), 8 deletions(-) diff --git a/src/app/valentina/mainwindowsnogui.cpp b/src/app/valentina/mainwindowsnogui.cpp index 782b0ddaf..d415bb900 100644 --- a/src/app/valentina/mainwindowsnogui.cpp +++ b/src/app/valentina/mainwindowsnogui.cpp @@ -464,13 +464,10 @@ void MainWindowsNoGUI::ExportDetailsAsApparelLayout(const DialogSaveLayout &dial for (int i=0; i < listDetails.count(); ++i) { - QTransform moveMatrix; - matrix = matrix.translate(listDetails.at(i).GetMx(), listDetails.at(i).GetMy()); - matrix = matrix.translate(-mx, -my); - moveMatrix *= listDetails.at(i).GetMatrix(); + QTransform moveMatrix = listDetails[i].GetMatrix(); + moveMatrix = moveMatrix.translate(listDetails.at(i).GetMx(), listDetails.at(i).GetMy()); + moveMatrix = moveMatrix.translate(-mx, -my); listDetails[i].SetMatrix(moveMatrix); - listDetails[i].SetMx(listDetails.at(i).GetMx()-mx); - listDetails[i].SetMy(listDetails.at(i).GetMy()-my); } const QString name = dialog.Path() + QLatin1String("/") + dialog.FileName() + QString::number(1) diff --git a/src/libs/vdxf/vdxfengine.cpp b/src/libs/vdxf/vdxfengine.cpp index aae30ac65..d152b0d27 100644 --- a/src/libs/vdxf/vdxfengine.cpp +++ b/src/libs/vdxf/vdxfengine.cpp @@ -648,8 +648,6 @@ bool VDxfEngine::ExportToAAMA(const QVector &details) DRW_Insert *insert = new DRW_Insert(); insert->name = blockName.toStdString(); - insert->basePoint = DRW_Coord(FromPixel(detail.GetMx(), varInsunits), - FromPixel(- detail.GetMy(), varInsunits), 0); insert->layer = "1"; input->AddEntity(insert);