diff --git a/src/aui/dockart.cpp b/src/aui/dockart.cpp index 9afb24c439..7818b2b8aa 100644 --- a/src/aui/dockart.cpp +++ b/src/aui/dockart.cpp @@ -765,6 +765,7 @@ void wxAuiDefaultDockArt::DrawPaneButton(wxDC& dc, break; } + bmp = wxAuiScaleBitmap(bmp, window->GetContentScaleFactor()); wxRect rect = _rect; @@ -791,10 +792,11 @@ void wxAuiDefaultDockArt::DrawPaneButton(wxDC& dc, } // draw the background behind the button - dc.DrawRectangle(rect.x, rect.y, 16-window->FromDIP(1), 16-window->FromDIP(1)); + dc.DrawRectangle(rect.x, rect.y, + bmp.GetScaledWidth() - window->FromDIP(1), + bmp.GetScaledHeight() - window->FromDIP(1)); } - // draw the button itself dc.DrawBitmap(bmp, rect.x, rect.y, true); }