summaryrefslogtreecommitdiff
path: root/sdext/source/pdfimport/tree/drawtreevisiting.cxx
diff options
context:
space:
mode:
authorIvo Hinkelmann <ihi@openoffice.org>2011-03-07 13:55:23 +0100
committerIvo Hinkelmann <ihi@openoffice.org>2011-03-07 13:55:23 +0100
commit39250f089adfce87856a0a7a250511decd7418e2 (patch)
treee4e5b62047222c7b461f8d92119ead7c42aa494f /sdext/source/pdfimport/tree/drawtreevisiting.cxx
parentec552c26abaa80dacb9f9b452d5b60dcfa8abd28 (diff)
parent1804e7477506b8fb7cddd9fe7765154df10f3727 (diff)
CWS-TOOLING: integrate CWS vcl119
Notes
Notes: split repo tag: extensions_ooo/DEV300_m102 split repo tag: extensions_ooo/DEV300_m103
Diffstat (limited to 'sdext/source/pdfimport/tree/drawtreevisiting.cxx')
-rw-r--r--sdext/source/pdfimport/tree/drawtreevisiting.cxx11
1 files changed, 8 insertions, 3 deletions
diff --git a/sdext/source/pdfimport/tree/drawtreevisiting.cxx b/sdext/source/pdfimport/tree/drawtreevisiting.cxx
index 5f1bb429ce8a..c68af3c37d86 100644
--- a/sdext/source/pdfimport/tree/drawtreevisiting.cxx
+++ b/sdext/source/pdfimport/tree/drawtreevisiting.cxx
@@ -212,7 +212,9 @@ void DrawXmlEmitter::visit( ParagraphElement& elem, const std::list< Element* >:
void DrawXmlEmitter::fillFrameProps( DrawElement& rElem,
PropertyMap& rProps,
- const EmitContext& rEmitContext )
+ const EmitContext& rEmitContext,
+ bool bWasTransformed
+ )
{
double rel_x = rElem.x, rel_y = rElem.y;
@@ -223,7 +225,7 @@ void DrawXmlEmitter::fillFrameProps( DrawElement& rElem,
const GraphicsContext& rGC =
rEmitContext.rProcessor.getGraphicsContext( rElem.GCId );
- if( rGC.Transformation.isIdentity() )
+ if( rGC.Transformation.isIdentity() || bWasTransformed )
{
rProps[ USTR( "svg:x" ) ] = convertPixelToUnitString( rel_x );
rProps[ USTR( "svg:y" ) ] = convertPixelToUnitString( rel_y );
@@ -350,7 +352,10 @@ void DrawXmlEmitter::visit( PolyPolyElement& elem, const std::list< Element* >::
}
PropertyMap aProps;
- fillFrameProps( elem, aProps, m_rEmitContext );
+ // PDFIProcessor transforms geometrical objects, not images and text
+ // so we need to tell fillFrameProps here that the transformation for
+ // a PolyPolyElement was already applied (aside form translation)
+ fillFrameProps( elem, aProps, m_rEmitContext, true );
rtl::OUStringBuffer aBuf( 64 );
aBuf.appendAscii( "0 0 " );
aBuf.append( convPx2mmPrec2(elem.w)*100.0 );