summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorSzymon Kłos <szymon.klos@collabora.com>2017-10-06 16:04:25 +0200
committerAndras Timar <andras.timar@collabora.com>2017-10-31 08:57:48 +0100
commit54293c1fae0c774c72a8564a25844aecf6d40f7f (patch)
treeed710710101110dff795e55a8951a1643f36c9ed /include
parente7a0948db44f049b1cf03a6e6fcaca7e63e88ac2 (diff)
SmartArt: export text rotation in the PPTX
Change-Id: I74bfc172fe7434d14de468ecfd3412636e53780c Reviewed-on: https://gerrit.libreoffice.org/43202 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Szymon Kłos <szymon.klos@collabora.com> Reviewed-on: https://gerrit.libreoffice.org/44080 Reviewed-by: Andras Timar <andras.timar@collabora.com> Tested-by: Andras Timar <andras.timar@collabora.com>
Diffstat (limited to 'include')
-rw-r--r--include/oox/drawingml/drawingmltypes.hxx15
1 files changed, 15 insertions, 0 deletions
diff --git a/include/oox/drawingml/drawingmltypes.hxx b/include/oox/drawingml/drawingmltypes.hxx
index 2aac13c669a7..aaed34b11ab9 100644
--- a/include/oox/drawingml/drawingmltypes.hxx
+++ b/include/oox/drawingml/drawingmltypes.hxx
@@ -150,6 +150,21 @@ struct IndexRange {
/** retrieve the content of CT_IndexRange */
IndexRange GetIndexRange( const css::uno::Reference< css::xml::sax::XFastAttributeList >& xAttributes );
+/**
+* nRotation is a 100th of a degree and the return value is
+* in a 60,000th of a degree
+*
+* Also rotation is in opposite directions so multiply with -1
+*/
+inline OString calcRotationValue(sal_Int32 nRotation)
+{
+ if (nRotation > 18000) // 180 degree
+ {
+ nRotation -= 36000;
+ }
+ nRotation *= -600;
+ return OString::number(nRotation);
+}
const sal_Int32 EMU_PER_HMM = 360; /// 360 EMUs per 1/100 mm.