diff options
author | Heiko Tietze <tietze.heiko@gmail.com> | 2021-11-17 15:38:02 +0100 |
---|---|---|
committer | Heiko Tietze <heiko.tietze@documentfoundation.org> | 2021-11-18 07:02:26 +0100 |
commit | f0334d62da608e140073e8831fdbbd0b5e4b1e39 (patch) | |
tree | fb6bf22027fdb64cf187fcfc74808db50a39ff8e /basctl | |
parent | 4be0ae19065b1b50870bc0b2a28189ad39c96a8a (diff) |
Resolves tdf#143462 - Fixes black row number on dark backgroud in Basic IDE
Using WindowColor for background and WindowTextColor for font color now
Change-Id: Ie7bcb66d43673722ac882ac3cd59c7d9106f3020
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125403
Tested-by: Jenkins
Reviewed-by: Heiko Tietze <heiko.tietze@documentfoundation.org>
Diffstat (limited to 'basctl')
-rw-r--r-- | basctl/source/basicide/linenumberwindow.cxx | 4 | ||||
-rw-r--r-- | basctl/source/basicide/linenumberwindow.hxx | 1 |
2 files changed, 4 insertions, 1 deletions
diff --git a/basctl/source/basicide/linenumberwindow.cxx b/basctl/source/basicide/linenumberwindow.cxx index be9fe3752045..7dcbff0ddd7f 100644 --- a/basctl/source/basicide/linenumberwindow.cxx +++ b/basctl/source/basicide/linenumberwindow.cxx @@ -21,7 +21,8 @@ LineNumberWindow::LineNumberWindow(vcl::Window* pParent, ModulWindow* pModulWind , m_pModulWindow(pModulWindow) , m_nCurYOffset(0) { - SetBackground(Wallpaper(GetSettings().GetStyleSettings().GetFieldColor())); + SetBackground(Wallpaper(GetSettings().GetStyleSettings().GetWindowColor())); + m_FontColor = GetSettings().GetStyleSettings().GetWindowTextColor(); m_nBaseWidth = GetTextWidth("8"); m_nWidth = m_nBaseWidth * 3 + m_nBaseWidth / 2; } @@ -78,6 +79,7 @@ void LineNumberWindow::Paint(vcl::RenderContext& rRenderContext, const tools::Re } sal_Int64 y = (nStartLine - 1) * static_cast<sal_Int64>(nLineHeight); + rRenderContext.SetTextColor(m_FontColor); for (sal_uInt32 n = nStartLine; n <= nEndLine; ++n, y += nLineHeight) rRenderContext.DrawText(Point(0, y - m_nCurYOffset), OUString::number(n)); } diff --git a/basctl/source/basicide/linenumberwindow.hxx b/basctl/source/basicide/linenumberwindow.hxx index 14305116ef10..a2e457f71103 100644 --- a/basctl/source/basicide/linenumberwindow.hxx +++ b/basctl/source/basicide/linenumberwindow.hxx @@ -22,6 +22,7 @@ private: int m_nWidth; tools::Long m_nCurYOffset; int m_nBaseWidth; + Color m_FontColor; virtual void DataChanged(DataChangedEvent const& rDCEvt) override; protected: |