diff options
author | Fridrich Štrba <fridrich.strba@bluewin.ch> | 2013-06-12 07:03:16 +0200 |
---|---|---|
committer | Fridrich Štrba <fridrich.strba@bluewin.ch> | 2013-06-12 07:03:49 +0200 |
commit | f387c5da5a824df6cf2874155c13445a86804475 (patch) | |
tree | 0c8cf29165302957234e9642f3efb3fc0d265021 | |
parent | d9b7d3a2dd943d246e7d09b3539628e2e357a307 (diff) |
Pass also the bounding box in device units to the EMF+ part
Change-Id: I71d3029d4b3aafdc44d82b0bd9db9a54f9b8b81f
-rw-r--r-- | cppcanvas/source/inc/implrenderer.hxx | 4 | ||||
-rw-r--r-- | cppcanvas/source/mtfrenderer/implrenderer.cxx | 2 | ||||
-rw-r--r-- | vcl/source/filter/wmf/winmtf.cxx | 7 |
3 files changed, 13 insertions, 0 deletions
diff --git a/cppcanvas/source/inc/implrenderer.hxx b/cppcanvas/source/inc/implrenderer.hxx index 79a2967f88d6..ae47ab806191 100644 --- a/cppcanvas/source/inc/implrenderer.hxx +++ b/cppcanvas/source/inc/implrenderer.hxx @@ -295,6 +295,10 @@ static float GetSwapFloat( SvStream& rSt ) sal_Int32 nHDPI; sal_Int32 nVDPI; /* EMF+ emf header info */ + sal_Int32 nBoundsLeft; + sal_Int32 nBoundsTop; + sal_Int32 nBoundsRight; + sal_Int32 nBoundsBottom; sal_Int32 nFrameLeft; sal_Int32 nFrameTop; sal_Int32 nFrameRight; diff --git a/cppcanvas/source/mtfrenderer/implrenderer.cxx b/cppcanvas/source/mtfrenderer/implrenderer.cxx index 85a5cef24b38..ca217d117a5b 100644 --- a/cppcanvas/source/mtfrenderer/implrenderer.cxx +++ b/cppcanvas/source/mtfrenderer/implrenderer.cxx @@ -1867,6 +1867,8 @@ namespace cppcanvas SvMemoryStream rMF ((void*) pAct->GetData (), pAct->GetDataSize (), STREAM_READ); + rMF >> nBoundsLeft >> nBoundsTop >> nBoundsRight >> nBoundsBottom; + SAL_INFO ("cppcanvas.emf", "EMF+ picture bounds: " << nBoundsLeft << "," << nBoundsTop << " - " << nBoundsRight << "," << nBoundsBottom); rMF >> nFrameLeft >> nFrameTop >> nFrameRight >> nFrameBottom; SAL_INFO ("cppcanvas.emf", "EMF+ picture frame: " << nFrameLeft << "," << nFrameTop << " - " << nFrameRight << "," << nFrameBottom); rMF >> nPixX >> nPixY >> nMmX >> nMmY; diff --git a/vcl/source/filter/wmf/winmtf.cxx b/vcl/source/filter/wmf/winmtf.cxx index 42d605c2e02c..ac3fec137baa 100644 --- a/vcl/source/filter/wmf/winmtf.cxx +++ b/vcl/source/filter/wmf/winmtf.cxx @@ -2233,14 +2233,21 @@ void WinMtfOutput::PassEMFPlusHeaderInfo() EMFP_DEBUG(printf ("\t\t\tadd EMF_PLUS header info\n")); SvMemoryStream mem; + sal_Int32 nDevLeft, nDevRight, nDevTop, nDevBottom; sal_Int32 nLeft, nRight, nTop, nBottom; + nDevLeft = mrclBounds.Left(); + nDevRight = mrclBounds.Right(); + nDevTop = mrclBounds.Top(); + nDevBottom = mrclBounds.Bottom(); + nLeft = mrclFrame.Left(); nTop = mrclFrame.Top(); nRight = mrclFrame.Right(); nBottom = mrclFrame.Bottom(); // emf header info + mem << nDevLeft << nDevTop << nDevRight << nDevBottom; mem << nLeft << nTop << nRight << nBottom; mem << mnPixX << mnPixY << mnMillX << mnMillY; |