Must strip menu codes from labels before measuring (fixes bug 1400552)

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@36971 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Julian Smart
2006-01-18 16:16:36 +00:00
parent 90c4e038d0
commit 9f8130d6b3
6 changed files with 6 additions and 6 deletions

View File

@@ -214,7 +214,7 @@ wxSize wxCheckBox::DoGetBestSize() const
int wCheckbox, hCheckbox;
if ( !str.IsEmpty() )
{
GetTextExtent(str, &wCheckbox, &hCheckbox);
GetTextExtent(wxStripMenuCodes(str), &wCheckbox, &hCheckbox);
wCheckbox += s_checkSize + GetCharWidth();
if ( hCheckbox < s_checkSize )