Code

fix-render-of-zero-dimension-rects
authorbuliabyak <buliabyak@users.sourceforge.net>
Mon, 25 Feb 2008 10:08:07 +0000 (10:08 +0000)
committerbuliabyak <buliabyak@users.sourceforge.net>
Mon, 25 Feb 2008 10:08:07 +0000 (10:08 +0000)
src/sp-rect.cpp

index cf399d3241159e3d8daa6fc68f31f9c9fdedd67e..55d2a3fde3b1fb14fff46d1e8446552f75ccb86e 100644 (file)
@@ -249,7 +249,10 @@ sp_rect_set_shape(SPShape *shape)
 {
     SPRect *rect = (SPRect *) shape;
 
-    if ((rect->height.computed < 1e-18) || (rect->width.computed < 1e-18)) return;
+    if ((rect->height.computed < 1e-18) || (rect->width.computed < 1e-18)) {
+        sp_shape_set_curve_insync(SP_SHAPE(rect), NULL, TRUE);
+        return;
+    }
 
     SPCurve *c = sp_curve_new();