diff options
| author | Jabier Arraiza Cenoz <jabier.arraiza@marker.es> | 2014-01-02 15:16:13 +0000 |
|---|---|---|
| committer | Jabiertxof <jtx@jtx.marker.es> | 2014-01-02 15:16:13 +0000 |
| commit | ada8e6c77eba1d1cda72eb239383171981e7c801 (patch) | |
| tree | 753c31c9adc0e733308317a5f204c767356ba611 /src/sp-item-transform.cpp | |
| parent | Fixed a boring bug sometimes curves be converted to lines, increasing a bit t... (diff) | |
| parent | Fix for Bug #950781 (There is no disk in drive error when opening Inkscape in... (diff) | |
| download | inkscape-ada8e6c77eba1d1cda72eb239383171981e7c801.tar.gz inkscape-ada8e6c77eba1d1cda72eb239383171981e7c801.zip | |
update to trunk
(bzr r11950.1.231)
Diffstat (limited to 'src/sp-item-transform.cpp')
| -rw-r--r-- | src/sp-item-transform.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/sp-item-transform.cpp b/src/sp-item-transform.cpp index 88148c789..2d1dd8193 100644 --- a/src/sp-item-transform.cpp +++ b/src/sp-item-transform.cpp @@ -140,11 +140,11 @@ Geom::Affine get_scale_transform_for_uniform_stroke(Geom::Rect const &bbox_visua gdouble scale_y = 1; gdouble r1 = r0; - if (fabs(w0 - r0) < 1e-6) { // We have a vertical line at hand + if ((fabs(w0 - r0) < 1e-6) || w1 == 0) { // We have a vertical line at hand r1 = transform_stroke ? r0 * sqrt(h1/h0) : r0; scale_x = 1; scale_y = preserve ? h1/h0 : (h1 - r1)/(h0 - r0); - } else if (fabs(h0 - r0) < 1e-6) { // We have a horizontal line at hand + } else if ((fabs(h0 - r0) < 1e-6) || h1 == 0) { // We have a horizontal line at hand r1 = transform_stroke ? r0 * sqrt(w1/w0) : r0; scale_x = preserve ? w1/w0 : (w1 - r1)/(w0 - r0); scale_y = 1; |
