don't use GetThemeMetric(HP_HEADERITEM, TMT_HEIGHT) as it doesn't seem to work; implement GetHeaderButtonHeight() in wxRendererMSW instead of doing it in wxRendererXP using HDM_LAYOUT; added test for this renderer method to the sample

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@48535 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Vadim Zeitlin
2007-09-03 21:50:28 +00:00
parent 7d8e5b8f04
commit 51c42fc50a
2 changed files with 39 additions and 30 deletions

View File

@@ -133,8 +133,10 @@ public:
dc.DrawText(_T("Below is the standard header button drawn"), 10, 10);
dc.DrawText(_T("using the current renderer:"), 10, 40);
wxRendererNative::Get().DrawHeaderButton(this, dc,
wxRect(20, 70, 100, 60));
wxRendererNative& renderer = wxRendererNative::Get();
const wxCoord height = renderer.GetHeaderButtonHeight(this);
renderer.DrawHeaderButton(this, dc, wxRect(20, 70, 100, height));
}
DECLARE_EVENT_TABLE()