]> git.saurik.com Git - wxWidgets.git/blobdiff - src/msw/stattext.cpp
fixed wxStaticText best size calculation (closes bug 667324)
[wxWidgets.git] / src / msw / stattext.cpp
index 6a2056e2afd2f838da72701f0df655df317600cb..14c62eca20a3ace748db6d4b6b2287294e3f1f64 100644 (file)
@@ -106,7 +106,10 @@ wxSize wxStaticText::DoGetBestSize() const
             }
         }
         else {
-            curLine += *pc;
+            // we shouldn't take into account the '&' which just introduce the
+            // mnemonic characters and so are not shown on the screen
+            if ( pc != _T('&') )
+                curLine += *pc;
         }
     }