summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDennis Francis <dennis.francis@collabora.com>2021-11-30 16:06:51 +0530
committerAndras Timar <andras.timar@collabora.com>2022-01-11 11:18:09 +0100
commit3df583520ee03bad42df09db7dde4c0c683a228b (patch)
tree6225e9f8dee88e6ceedefd36306895318b405914
parent18038bd35c01abf1aad69932c4a7e75988921289 (diff)
lokCalcRTL: negate the +ve shape handle X coordinate...
...from lok client as all shape X coordinates are negative in lok-RTL mode. Change-Id: Ic4ba064888901109c85760bb0afda609b5d5942c
-rw-r--r--sc/source/ui/drawfunc/drawsh.cxx5
1 files changed, 4 insertions, 1 deletions
diff --git a/sc/source/ui/drawfunc/drawsh.cxx b/sc/source/ui/drawfunc/drawsh.cxx
index a0bcc3a78a3b..278a063c6c7b 100644
--- a/sc/source/ui/drawfunc/drawsh.cxx
+++ b/sc/source/ui/drawfunc/drawsh.cxx
@@ -60,6 +60,7 @@
#include <svx/xflgrit.hxx>
#include <editeng/colritem.hxx>
#include <tools/UnitConversion.hxx>
+#include <comphelper/lok.hxx>
SFX_IMPL_INTERFACE(ScDrawShell, SfxShell)
@@ -216,7 +217,9 @@ void ScDrawShell::ExecDrawAttr( SfxRequest& rReq )
const sal_uLong handleNum = handleNumItem->GetValue();
const sal_uLong newPosX = convertTwipToMm100(newPosXTwips->GetValue());
const sal_uLong newPosY = convertTwipToMm100(newPosYTwips->GetValue());
- pView->MoveShapeHandle(handleNum, Point(newPosX, newPosY), OrdNum ? OrdNum->GetValue() : -1);
+
+ bool bNegateX = comphelper::LibreOfficeKit::isActive() && rViewData.GetDocument().IsLayoutRTL(rViewData.GetTabNo());
+ pView->MoveShapeHandle(handleNum, Point(bNegateX ? -newPosX : newPosX, newPosY), OrdNum ? OrdNum->GetValue() : -1);
}
}
break;