[Kst] branches/work/kst/portto4/kst/src/libkstmath

Peter Kümmel syntheticpp at yahoo.com
Thu Mar 11 21:47:10 CET 2010


SVN commit 1102104 by kuemmel:

don't copy vectors

 M  +5 -5      curve.cpp  


--- branches/work/kst/portto4/kst/src/libkstmath/curve.cpp #1102103:1102104
@@ -656,22 +656,22 @@
       p->setPen(QPen(color(), _width, style));
     }
 
-    foreach(QRectF rect, _filledRects) {
+    foreach(const QRectF& rect, _filledRects) {
         p->fillRect(rect, color());
     }
   }
   p->setPen(QPen(color(), _width, style));
 
-  foreach(QPolygonF poly, _polygons) {
+  foreach(const QPolygonF& poly, _polygons) {
     p->drawPolyline(poly);
   }
-  foreach(QLineF line, _lines) {
+  foreach(const QLineF& line, _lines) {
     p->drawLine(line);
   }
-  foreach(QRectF rect, _rects) {
+  foreach(const QRectF& rect, _rects) {
     p->drawRect(rect);
   }
-  foreach(QPointF point, _points) {
+  foreach(const QPointF& point, _points) {
     CurvePointSymbol::draw(PointType, p, point.x(), point.y(), _width);
   }
   p->restore();


More information about the Kst mailing list