Merge with develop.

--HG--
branch : feature
This commit is contained in:
Roman Telezhynskyi 2016-04-10 14:50:56 +03:00
commit a7c4cc7aaf
2 changed files with 8 additions and 5 deletions

View File

@ -1,4 +1,5 @@
# Version 0.5.0 # Version 0.5.0
- [#193] Undeletable zombie arc objects.
- New feature. Groups. - New feature. Groups.
- Tool "Curve intersect axis" store data about subpaths. - Tool "Curve intersect axis" store data about subpaths.
- [#444] Length along Path seems not valid. - [#444] Length along Path seems not valid.

View File

@ -178,14 +178,16 @@ QPointF VArc::GetP2 () const
*/ */
qreal VArc::AngleArc() const qreal VArc::AngleArc() const
{ {
if ((qFuzzyIsNull(d->f1) && qFuzzyCompare(d->f2, 360)) || {
(qFuzzyCompare(d->f1, 360) && qFuzzyIsNull(d->f2))) const qreal angleDiff = qAbs(d->f1 - d->f2);
if (VFuzzyComparePossibleNulls(angleDiff, 0) || VFuzzyComparePossibleNulls(angleDiff, 360))
{ {
return 360; return 360;
} }
QLineF l1(0, 0, 100, 100); }
QLineF l1(0, 0, 100, 0);
l1.setAngle(d->f1); l1.setAngle(d->f1);
QLineF l2(0, 0, 100, 100); QLineF l2(0, 0, 100, 0);
l2.setAngle(d->f2); l2.setAngle(d->f2);
qreal ang = l1.angleTo(l2); qreal ang = l1.angleTo(l2);