summaryrefslogtreecommitdiffstats
path: root/src/sp-item-transform.cpp
diff options
context:
space:
mode:
authorJabier Arraiza Cenoz <jabier.arraiza@marker.es>2014-01-20 09:45:43 +0000
committerJabiertxof <jtx@jtx.marker.es>2014-01-20 09:45:43 +0000
commita9ead40d7ef23b967f42333ec58b54266a8553a5 (patch)
tree73841e63909abc4e982ca26f9dff122eb21e48d4 /src/sp-item-transform.cpp
parentupdate to trunk (diff)
parentRevert changes from r12959 and r12955, impliment new stratedgy to fix bug #16... (diff)
downloadinkscape-a9ead40d7ef23b967f42333ec58b54266a8553a5.tar.gz
inkscape-a9ead40d7ef23b967f42333ec58b54266a8553a5.zip
update to trunk
(bzr r11950.1.236)
Diffstat (limited to 'src/sp-item-transform.cpp')
-rw-r--r--src/sp-item-transform.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/sp-item-transform.cpp b/src/sp-item-transform.cpp
index 9dbe412d7..854fb9cd7 100644
--- a/src/sp-item-transform.cpp
+++ b/src/sp-item-transform.cpp
@@ -110,6 +110,9 @@ Geom::Affine get_scale_transform_for_uniform_stroke(Geom::Rect const &bbox_visua
// -> The width and height of the geometric bounding box will therefore be (w0 - 2*0.5*r0) and (h0 - 2*0.5*r0)
// 4) If preserve transforms is true, then stroke_x != stroke_y, since these are the apparent stroke widths, after transforming
+ if ((stroke_x == Geom::infinity()) || (fabs(stroke_x) < 1e-6)) stroke_x = 0;
+ if ((stroke_y == Geom::infinity()) || (fabs(stroke_y) < 1e-6)) stroke_y = 0;
+
gdouble w0 = bbox_visual.width(); // will return a value >= 0, as required further down the road
gdouble h0 = bbox_visual.height();
gdouble r0 = sqrt(stroke_x*stroke_y); // r0 is redundant, used only for those cases where stroke_x = stroke_y