Code

Replace isspace() with isWhitespace(). Use pure unicode character classes.
[inkscape.git] / src / selection.cpp
index 4c99885eb389c16e82d54186614e8d2bd423d5d4..c40b7b546346da91531deac04cb8bc8a53e437e9 100644 (file)
@@ -290,7 +290,7 @@ NRRect *Selection::bounds(NRRect *bbox) const
     bbox->x0 = b.min()[NR::X];
     bbox->y0 = b.min()[NR::Y];
     bbox->x1 = b.max()[NR::X];
-    bbox->x1 = b.max()[NR::Y];
+    bbox->y1 = b.max()[NR::Y];
     return bbox;
 }
 
@@ -357,20 +357,20 @@ std::vector<NR::Point> Selection::getSnapPointsConvexHull() const {
     for (GSList const *iter = items; iter != NULL; iter = iter->next) {
        sp_item_snappoints(SP_ITEM(iter->data), SnapPointsIter(p));
     }
-    
-    std::vector<NR::Point>::iterator i; 
+
+    std::vector<NR::Point>::iterator i;
     NR::ConvexHull cvh(*(p.begin()));
     for (i = p.begin(); i != p.end(); i++) {
        // these are the points we get back
-       cvh.add(*i); 
+       cvh.add(*i);
     }
-    
-    NR::Rect rHull = cvh.bounds(); 
-    std::vector<NR::Point> pHull(4); 
-    pHull[0] = rHull.corner(0); 
-    pHull[1] = rHull.corner(1); 
-    pHull[2] = rHull.corner(2); 
-    pHull[3] = rHull.corner(3); 
+
+    NR::Rect rHull = cvh.bounds();
+    std::vector<NR::Point> pHull(4);
+    pHull[0] = rHull.corner(0);
+    pHull[1] = rHull.corner(1);
+    pHull[2] = rHull.corner(2);
+    pHull[3] = rHull.corner(3);
 
     return pHull;
 }