svtools/source/control/tabbar.cxx | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-)
New commits: commit 1045aeecb20aeefd7f6181288853f9a89305c9ba Author: Rafael Lima <rafael.palma.l...@gmail.com> AuthorDate: Sat Oct 1 00:38:46 2022 +0200 Commit: Adolfo Jayme Barrientos <fit...@ubuntu.com> CommitDate: Thu Oct 6 06:45:08 2022 +0200 tdf#148938 Fix position arrows when dragging Calc tabs in dark mode In Calc, when you drag a tab to move it, the arrows pointing to where the tab will be positioned are always in black, even in dark mode. This patch fixes this issue. Change-Id: I9079099c5ac1a8fb767eaa105cf8863e54d0ec3f Reviewed-on: https://gerrit.libreoffice.org/c/core/+/140760 Tested-by: Jenkins Reviewed-by: Adolfo Jayme Barrientos <fit...@ubuntu.com> diff --git a/svtools/source/control/tabbar.cxx b/svtools/source/control/tabbar.cxx index 700c1c37767b..1e9a9172967f 100644 --- a/svtools/source/control/tabbar.cxx +++ b/svtools/source/control/tabbar.cxx @@ -2331,7 +2331,8 @@ sal_uInt16 TabBar::ShowDropPos(const Point& rPos) } // draw drop position arrows - Color aBlackColor(COL_BLACK); + const StyleSettings& rStyles = Application::GetSettings().GetStyleSettings(); + const Color aTextColor = rStyles.GetLabelTextColor(); tools::Long nX; tools::Long nY = (maWinSize.Height() / 2) - 1; sal_uInt16 nCurPos = GetPagePos(mnCurPageId); @@ -2340,8 +2341,8 @@ sal_uInt16 TabBar::ShowDropPos(const Point& rPos) if (mnDropPos < nItemCount) { - GetOutDev()->SetLineColor(aBlackColor); - GetOutDev()->SetFillColor(aBlackColor); + GetOutDev()->SetLineColor(aTextColor); + GetOutDev()->SetFillColor(aTextColor); auto& rItem = mpImpl->maItemList[mnDropPos]; nX = rItem.maRect.Left(); @@ -2364,8 +2365,8 @@ sal_uInt16 TabBar::ShowDropPos(const Point& rPos) } if (mnDropPos > 0 && mnDropPos < nItemCount + 1) { - GetOutDev()->SetLineColor(aBlackColor); - GetOutDev()->SetFillColor(aBlackColor); + GetOutDev()->SetLineColor(aTextColor); + GetOutDev()->SetFillColor(aTextColor); auto& rItem = mpImpl->maItemList[mnDropPos - 1]; nX = rItem.maRect.Right();