Code

Revert fix for 515237 which introduces a catastrophic bug
authorKrzysztof Kosiński <tweenk.pl@gmail.com>
Sun, 7 Feb 2010 02:20:50 +0000 (03:20 +0100)
committerKrzysztof Kosiński <tweenk.pl@gmail.com>
Sun, 7 Feb 2010 02:20:50 +0000 (03:20 +0100)
src/2geom/path.cpp

index 05a69d616371e2870a1d666697be4173bdfc5d4b..88c7a99b9df9af99c8d1e3112cfb8e03c7825700 100644 (file)
@@ -89,17 +89,8 @@ Path &Path::operator*=(Matrix const &m) {
     }
     prev = (*it)->finalPoint();
   }
-  if (closed_) {
-    Geom::Point pt = front().initialPoint();
-    if (size_open() > 0) {
-        Curve *l = const_cast<Curve*>((get_curves().end() - 2)->get());
-        l->setFinal(pt);
-    }
-    final_->setInitial(pt);
-    final_->setFinal(pt);
-  } else {
-    final_->setInitial(back().finalPoint());
-    final_->setFinal(front().initialPoint());
+  for ( int i = 0 ; i < 2 ; ++i ) {
+    final_->setPoint(i, (*final_)[i] * m);
   }
   if (get_curves().size() > 1) {
     if ( front().initialPoint() != initialPoint() || back().finalPoint() != finalPoint() ) {