Make wxStaticText for OS X Cocoa properly size multiline strings.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@59347 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Kevin Ollivier
2009-03-05 19:20:36 +00:00
parent 724999ee87
commit 16747764fb

View File

@@ -48,7 +48,7 @@ Point bounds;
{
wxClientDC dc(const_cast<wxStaticText*>(this));
wxCoord width, height ;
dc.GetTextExtent( m_label , &width, &height);
dc.GetMultiLineTextExtent( m_label , &width, &height);
// Some labels seem to have their last characters
// stripped out. Adding 4 pixels seems to be enough to fix this.
bounds.h = width+4;