From 0ec6da024886a8cb387f2d8c5f293edf5a16e231 Mon Sep 17 00:00:00 2001 From: Julian Smart Date: Thu, 25 Oct 2007 14:53:07 +0000 Subject: [PATCH] Now uses the correct selection colours. git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@49430 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- src/richtext/richtextbuffer.cpp | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/src/richtext/richtextbuffer.cpp b/src/richtext/richtextbuffer.cpp index 3f69ec3..c8547b3 100644 --- a/src/richtext/richtextbuffer.cpp +++ b/src/richtext/richtextbuffer.cpp @@ -28,6 +28,7 @@ #include "wx/module.h" #endif +#include "wx/settings.h" #include "wx/filename.h" #include "wx/clipbrd.h" #include "wx/wfstream.h" @@ -4258,9 +4259,12 @@ bool wxRichTextPlainText::DrawTabbedString(wxDC& dc, const wxTextAttr& attr, con if (selected) { - dc.SetBrush(*wxBLACK_BRUSH); - dc.SetPen(*wxBLACK_PEN); - dc.SetTextForeground(*wxWHITE); + wxColour highlightColour(wxSystemSettings::GetColour(wxSYS_COLOUR_HIGHLIGHT)); + wxColour highlightTextColour(wxSystemSettings::GetColour(wxSYS_COLOUR_HIGHLIGHTTEXT)); + + dc.SetBrush(wxBrush(highlightColour)); + dc.SetPen(wxPen(highlightColour)); + dc.SetTextForeground(highlightTextColour); dc.SetBackgroundMode(wxTRANSPARENT); } else -- 2.7.4