Code

correct intersection since we allow empty rects again
authormental <mental@users.sourceforge.net>
Sun, 18 Mar 2007 23:22:09 +0000 (23:22 +0000)
committermental <mental@users.sourceforge.net>
Sun, 18 Mar 2007 23:22:09 +0000 (23:22 +0000)
src/libnr/nr-rect.cpp

index dbb54b9fdd3d52d51e36529032418579da39a020..72bced37bb048ca9337d8c03658710f412c2dd81 100644 (file)
@@ -304,7 +304,7 @@ Maybe<Rect> intersection(Maybe<Rect> const & a, Maybe<Rect> const & b) {
         for ( int i=0 ; i < 2 ; i++ ) {
             r._min[i] = std::max(a->_min[i], b->_min[i]);
             r._max[i] = std::min(a->_max[i], b->_max[i]);
-            if ( r._min[i] >= r._max[i] ) {
+            if ( r._min[i] > r._max[i] ) {
                return Nothing();
             }
        }