Fixed issue #696. Wrong grainline position on layout.

(grafted from 23e7ca4bff38c47729324aaa081d601351844035)

--HG--
branch : develop
This commit is contained in:
Roman Telezhynskyi 2017-05-29 17:45:55 +03:00
parent 9287acf90e
commit 4d1c15c2d5
2 changed files with 4 additions and 4 deletions

View File

@ -13,6 +13,7 @@
- Fixed bug in dialog Internal Piece Path. Value from the field After rewrited data in the field Before.
- Tab Pins moved to be second in the list after tab Paths.
- Added tooltip for tab Passmark. Explained meaning of check box "Show the second passmark on seam line".
- [#696] Wrong grainline position on layout.
# Version 0.5.0 May 9, 2017
- [#581] User can now filter input lists by keyword in function wizard.

View File

@ -214,13 +214,12 @@ bool FindGrainlineGeometry(const VGrainlineData& geom, const VContainer *pattern
{
const auto centerPinPoint = pattern->GeometricObject<VPointF>(centerPin);
const qreal cLength = ToPixel(length, *pattern->GetPatternUnit());
QLineF grainline(centerPinPoint->x(), centerPinPoint->y(),
centerPinPoint->x() + cLength / 2.0, centerPinPoint->y());
centerPinPoint->x() + length / 2.0, centerPinPoint->y());
grainline.setAngle(rotationAngle);
grainline.setAngle(qRadiansToDegrees(rotationAngle));
grainline = QLineF(grainline.p2(), grainline.p1());
grainline.setLength(cLength);
grainline.setLength(length);
pos = grainline.p2();
}