diff options
Diffstat (limited to 'sc/source/ui/view/drawview.cxx')
-rw-r--r-- | sc/source/ui/view/drawview.cxx | 16 |
1 files changed, 11 insertions, 5 deletions
diff --git a/sc/source/ui/view/drawview.cxx b/sc/source/ui/view/drawview.cxx index 43704c80e17d..86042772f399 100644 --- a/sc/source/ui/view/drawview.cxx +++ b/sc/source/ui/view/drawview.cxx @@ -965,7 +965,7 @@ void ScDrawView::SyncForGrid( SdrObject* pObj ) Point aCurPosHmm = pGridWin->PixelToLogic(aCurPos, aDrawMode ); Point aGridOff = aCurPosHmm - aOldPos; // fdo#63878 Fix the X position for RTL Sheet - if( rDoc.IsNegativePage( GetTab() ) ) + if( rDoc.IsNegativePage( GetTab() ) && !comphelper::LibreOfficeKit::isActive() ) aGridOff.setX( aCurPosHmm.getX() + aOldPos.getX() ); } @@ -1044,13 +1044,16 @@ bool ScDrawView::calculateGridOffsetForSdrObject( Point aCurPosHmm(pGridWin->PixelToLogic(aCurPos, aDrawMode)); Point aGridOff(aCurPosHmm - aOldPos); + bool bLOKActive = comphelper::LibreOfficeKit::isActive(); + bool bNegativePage = rDoc.IsNegativePage(GetTab()); + // fdo#63878 Fix the X position for RTL Sheet - if(rDoc.IsNegativePage(GetTab())) + if(bNegativePage && !bLOKActive) { aGridOff.setX(aCurPosHmm.getX() + aOldPos.getX()); } - rTarget.setX(aGridOff.X()); + rTarget.setX(bNegativePage && bLOKActive ? -aGridOff.X() : aGridOff.X()); rTarget.setY(aGridOff.Y()); return true; } @@ -1092,13 +1095,16 @@ bool ScDrawView::calculateGridOffsetForB2DRange( Point aCurPosHmm(pGridWin->PixelToLogic(aCurPos, aDrawMode)); Point aGridOff(aCurPosHmm - aOldPos); + bool bLOKActive = comphelper::LibreOfficeKit::isActive(); + bool bNegativePage = rDoc.IsNegativePage(GetTab()); + // fdo#63878 Fix the X position for RTL Sheet - if(rDoc.IsNegativePage(GetTab())) + if(bNegativePage && !bLOKActive) { aGridOff.setX(aCurPosHmm.getX() + aOldPos.getX()); } - rTarget.setX(aGridOff.X()); + rTarget.setX(bLOKActive && bNegativePage ? -aGridOff.X() : aGridOff.X()); rTarget.setY(aGridOff.Y()); return true; } |