From c50e44b270bc3048ff9c1a000c3afed1dab9e0bf Mon Sep 17 00:00:00 2001 From: Gülşah Köse Date: Thu, 3 Oct 2019 08:37:00 +0300 Subject: tdf#126060 Handle text camera z rotation while pptx import. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Change-Id: Ifa4589fb50affc4c5ffb52288db8533c98ec6dd9 Reviewed-on: https://gerrit.libreoffice.org/80587 Tested-by: Jenkins Reviewed-by: Gülşah Köse --- oox/source/drawingml/shape.cxx | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'oox/source/drawingml/shape.cxx') diff --git a/oox/source/drawingml/shape.cxx b/oox/source/drawingml/shape.cxx index 25d94efee180..4e574af50869 100644 --- a/oox/source/drawingml/shape.cxx +++ b/oox/source/drawingml/shape.cxx @@ -1380,7 +1380,11 @@ Reference< XShape > const & Shape::createAndInsert( mpCustomShapePropertiesPtr->setMirroredY( true ); if( getTextBody() ) { + sal_Int32 nTextCameraZRotation = static_cast< sal_Int32 >( get3DProperties().maCameraRotation.mnRevolution.get() ); + mpCustomShapePropertiesPtr->setTextCameraZRotateAngle( nTextCameraZRotation / 60000 ); + sal_Int32 nTextRotateAngle = static_cast< sal_Int32 >( getTextBody()->getTextProperties().moRotation.get( 0 ) ); + nTextRotateAngle -= mnDiagramRotation; /* OOX measures text rotation clockwise in 1/60000th degrees, relative to the containing shape. setTextRotateAngle wants -- cgit