From 11e52fe2979b0947814a49b9c17ec373795cbf8e Mon Sep 17 00:00:00 2001 From: Noel Date: Tue, 22 Dec 2020 15:42:08 +0200 Subject: introduce Degree100 strong_int type Change-Id: I78f837a1340be0ca5c49097f543a481b7b43a632 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/108367 Tested-by: Jenkins Reviewed-by: Noel Grandin --- include/oox/export/drawingml.hxx | 4 ++-- include/oox/vml/vmlformatting.hxx | 3 ++- 2 files changed, 4 insertions(+), 3 deletions(-) (limited to 'include/oox') diff --git a/include/oox/export/drawingml.hxx b/include/oox/export/drawingml.hxx index 022a0df00e4e..2cd17e6defb0 100644 --- a/include/oox/export/drawingml.hxx +++ b/include/oox/export/drawingml.hxx @@ -111,9 +111,9 @@ public: // Our rotation is counter-clockwise and is in 100ths of a degree. // drawingML rotation is clockwise and is in 60000ths of a degree. -template T ExportRotateClockwisify(T input) +inline sal_Int32 ExportRotateClockwisify(Degree100 input) { - return ((21600000 - input * 600) % 21600000); + return ((21600000 - input.get() * 600) % 21600000); } /// Interface to be implemented by the parent exporter that knows how to handle shape text. diff --git a/include/oox/vml/vmlformatting.hxx b/include/oox/vml/vmlformatting.hxx index 3d6cdc5ab87b..4bdabbffb97b 100644 --- a/include/oox/vml/vmlformatting.hxx +++ b/include/oox/vml/vmlformatting.hxx @@ -32,6 +32,7 @@ #include #include #include +#include namespace com::sun::star { namespace awt { struct Point; } @@ -87,7 +88,7 @@ namespace ConversionHelper point value will be returned unmodified. If the 'fd' suffix is present, the value will be divided by 65536. */ - OOX_DLLPUBLIC sal_Int32 decodeRotation( const OUString& rValue ); + OOX_DLLPUBLIC Degree100 decodeRotation( const OUString& rValue ); /** Converts the passed VML measure string to EMU (English Metric Units). -- cgit