X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/edc973b1749e09a437f8043e9833383b0f2457cb..1f6189acd0ebe8e27c4a71cc39b709784de26024:/src/gtk1/choice.cpp diff --git a/src/gtk1/choice.cpp b/src/gtk1/choice.cpp index c9e3cceac2..485f3fbdfb 100644 --- a/src/gtk1/choice.cpp +++ b/src/gtk1/choice.cpp @@ -448,14 +448,11 @@ wxSize wxChoice::DoGetBestSize() const ret.x = 0; if ( m_widget ) { - GdkFont *font = m_font.GetInternalFont(); - - wxCoord width; + int width; size_t count = GetCount(); for ( size_t n = 0; n < count; n++ ) { - // FIXME GTK 2.0 - width = (wxCoord)gdk_string_width(font, wxGTK_CONV( GetString(n) ) ); + GetTextExtent( GetString(n), &width, NULL, NULL, NULL, &m_font ); if ( width > ret.x ) ret.x = width; }