sc/source/ui/view/gridwin4.cxx | 9 +++++++++ 1 file changed, 9 insertions(+)
New commits: commit 3cd2d9665fba5723ac84732fcf41dc675577f08c Author: Dennis Francis <dennis.fran...@collabora.com> AuthorDate: Thu Jan 6 15:12:16 2022 +0530 Commit: Dennis Francis <dennis.fran...@collabora.com> CommitDate: Sat Feb 5 09:57:03 2022 +0100 lokCalcRTL: trim invalidation rect to ensure +ve X Change-Id: Ifecb52167e3cddee036e1e1e9bd5782a1138b654 (cherry picked from commit c2cbe0dbe4c9e4ce8014e881ba3663add77f7aca) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/129364 Tested-by: Jenkins Reviewed-by: Dennis Francis <dennis.fran...@collabora.com> diff --git a/sc/source/ui/view/gridwin4.cxx b/sc/source/ui/view/gridwin4.cxx index d83c2bcccde2..f71c73514a27 100644 --- a/sc/source/ui/view/gridwin4.cxx +++ b/sc/source/ui/view/gridwin4.cxx @@ -1673,6 +1673,15 @@ void ScGridWindow::LogicInvalidate(const tools::Rectangle* pRectangle) pResultRectangle = &aRectangle; } + // Trim invalidation rectangle overlapping negative X region in RTL mode. + if (pResultRectangle && pResultRectangle->Left() < 0 + && mrViewData.GetDocument().IsLayoutRTL(mrViewData.GetTabNo())) + { + pResultRectangle->SetLeft(0); + if (pResultRectangle->Right() < 0) + pResultRectangle->SetRight(0); + } + ScTabViewShell* pViewShell = mrViewData.GetViewShell(); SfxLokHelper::notifyInvalidation(pViewShell, pResultRectangle); }