git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@41536
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
static const int FRAME_BUTTON_WIDTH = 16;
static const int FRAME_BUTTON_HEIGHT = 14;
static const int FRAME_BUTTON_WIDTH = 16;
static const int FRAME_BUTTON_HEIGHT = 14;
+// the margin between listbox item text and its rectangle
+static const int ITEM_MARGIN = 1;
+
// ============================================================================
// wxStdRenderer implementation
// ============================================================================
// ============================================================================
// wxStdRenderer implementation
// ============================================================================
wxCoord wxStdRenderer::GetListboxItemHeight(wxCoord fontHeight)
{
wxCoord wxStdRenderer::GetListboxItemHeight(wxCoord fontHeight)
{
+ return fontHeight + 2*ITEM_MARGIN;
}
void wxStdRenderer::DrawTextBorder(wxDC& dc,
}
void wxStdRenderer::DrawTextBorder(wxDC& dc,
dc.DrawRectangle(rect);
}
dc.DrawRectangle(rect);
}
+ // horizontal adjustment is arbitrary
- rectText.x += 2;
- rectText.width -= 2;
+ rectText.Deflate(2, ITEM_MARGIN);
dc.DrawLabel(label, wxNullBitmap, rectText);
if ( flags & wxCONTROL_FOCUSED )
dc.DrawLabel(label, wxNullBitmap, rectText);
if ( flags & wxCONTROL_FOCUSED )