From dd864cffe0daab175c4f807d096f469ea191934b Mon Sep 17 00:00:00 2001 From: Paul Cornett Date: Fri, 20 Nov 2020 21:46:09 -0800 Subject: [PATCH] Fix border drawing glitch in wxGrid column header See #18980 --- src/generic/grid.cpp | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/src/generic/grid.cpp b/src/generic/grid.cpp index 2e9f4bdc5e..585f0b0a97 100644 --- a/src/generic/grid.cpp +++ b/src/generic/grid.cpp @@ -6901,8 +6901,11 @@ void wxGrid::DrawColLabel(wxDC& dc, int col) { // It is reported that we need to erase the background to avoid display // artefacts, see #12055. - wxDCBrushChanger setBrush(dc, m_colLabelWin->GetBackgroundColour()); - dc.DrawRectangle(rect); + { + wxDCBrushChanger setBrush(dc, m_colLabelWin->GetBackgroundColour()); + wxDCPenChanger setPen(dc, *wxTRANSPARENT_PEN); + dc.DrawRectangle(rect); + } rend.DrawBorder(*this, dc, rect); }