summaryrefslogtreecommitdiffstats
path: root/src/extension/internal/wmf-print.cpp
diff options
context:
space:
mode:
authorJabier Arraiza Cenoz <jabier.arraiza@marker.es>2013-10-26 12:27:05 +0000
committerJabiertxof <jtx@jtx.marker.es>2013-10-26 12:27:05 +0000
commit9b2d4924cf0f30df461236c7850c8e38480d8ad3 (patch)
tree560ebd4e32dc9c9645287e8f5a8470bde91d7817 /src/extension/internal/wmf-print.cpp
parentUpdate to trunk (diff)
parentFix memleak in reference counting introduced in r12532. (diff)
downloadinkscape-9b2d4924cf0f30df461236c7850c8e38480d8ad3.tar.gz
inkscape-9b2d4924cf0f30df461236c7850c8e38480d8ad3.zip
Update to trunk
(bzr r11950.1.189)
Diffstat (limited to 'src/extension/internal/wmf-print.cpp')
-rw-r--r--src/extension/internal/wmf-print.cpp5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/extension/internal/wmf-print.cpp b/src/extension/internal/wmf-print.cpp
index cf0302b38..3bb17146c 100644
--- a/src/extension/internal/wmf-print.cpp
+++ b/src/extension/internal/wmf-print.cpp
@@ -1120,6 +1120,9 @@ unsigned int PrintWmf::image(
Geom::Point pLL(x1, y1);
Geom::Point pLL2 = pLL * tf; //location of LL corner in Inkscape coordinates
+ Geom::Point pWH(dw, dh);
+ Geom::Point pWH2 = pWH * tf.withoutTranslation(); //adjust scale
+
char *px;
uint32_t cbPx;
uint32_t colortype;
@@ -1133,7 +1136,7 @@ unsigned int PrintWmf::image(
Bmi = bitmapinfo_set(Bmih, ct);
U_POINT16 Dest = point16_set(round(pLL2[Geom::X] * PX2WORLD), round(pLL2[Geom::Y] * PX2WORLD));
- U_POINT16 cDest = point16_set(round(dw * PX2WORLD), round(dh * PX2WORLD));
+ U_POINT16 cDest = point16_set(round(pWH2[Geom::X] * PX2WORLD), round(pWH2[Geom::Y] * PX2WORLD));
U_POINT16 Src = point16_set(0, 0);
U_POINT16 cSrc = point16_set(w, h);
rec = U_WMRSTRETCHDIB_set(