Removed usage of GetInternalFont.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@18595 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -448,14 +448,11 @@ wxSize wxChoice::DoGetBestSize() const
|
|||||||
ret.x = 0;
|
ret.x = 0;
|
||||||
if ( m_widget )
|
if ( m_widget )
|
||||||
{
|
{
|
||||||
GdkFont *font = m_font.GetInternalFont();
|
int width;
|
||||||
|
|
||||||
wxCoord width;
|
|
||||||
size_t count = GetCount();
|
size_t count = GetCount();
|
||||||
for ( size_t n = 0; n < count; n++ )
|
for ( size_t n = 0; n < count; n++ )
|
||||||
{
|
{
|
||||||
// FIXME GTK 2.0
|
GetTextExtent( GetString(n), &width, NULL, NULL, NULL, &m_font );
|
||||||
width = (wxCoord)gdk_string_width(font, wxGTK_CONV( GetString(n) ) );
|
|
||||||
if ( width > ret.x )
|
if ( width > ret.x )
|
||||||
ret.x = width;
|
ret.x = width;
|
||||||
}
|
}
|
||||||
|
@@ -750,13 +750,11 @@ wxSize wxComboBox::DoGetBestSize() const
|
|||||||
ret.x = 0;
|
ret.x = 0;
|
||||||
if ( m_widget )
|
if ( m_widget )
|
||||||
{
|
{
|
||||||
GdkFont *font = m_font.GetInternalFont();
|
int width;
|
||||||
|
size_t count = GetCount();
|
||||||
wxCoord width;
|
|
||||||
size_t count = Number();
|
|
||||||
for ( size_t n = 0; n < count; n++ )
|
for ( size_t n = 0; n < count; n++ )
|
||||||
{
|
{
|
||||||
width = (wxCoord)gdk_string_width(font, wxGTK_CONV( GetString(n) ) );
|
GetTextExtent( GetString(n), &width, NULL, NULL, NULL, &m_font );
|
||||||
if ( width > ret.x )
|
if ( width > ret.x )
|
||||||
ret.x = width;
|
ret.x = width;
|
||||||
}
|
}
|
||||||
|
@@ -448,14 +448,11 @@ wxSize wxChoice::DoGetBestSize() const
|
|||||||
ret.x = 0;
|
ret.x = 0;
|
||||||
if ( m_widget )
|
if ( m_widget )
|
||||||
{
|
{
|
||||||
GdkFont *font = m_font.GetInternalFont();
|
int width;
|
||||||
|
|
||||||
wxCoord width;
|
|
||||||
size_t count = GetCount();
|
size_t count = GetCount();
|
||||||
for ( size_t n = 0; n < count; n++ )
|
for ( size_t n = 0; n < count; n++ )
|
||||||
{
|
{
|
||||||
// FIXME GTK 2.0
|
GetTextExtent( GetString(n), &width, NULL, NULL, NULL, &m_font );
|
||||||
width = (wxCoord)gdk_string_width(font, wxGTK_CONV( GetString(n) ) );
|
|
||||||
if ( width > ret.x )
|
if ( width > ret.x )
|
||||||
ret.x = width;
|
ret.x = width;
|
||||||
}
|
}
|
||||||
|
@@ -750,13 +750,11 @@ wxSize wxComboBox::DoGetBestSize() const
|
|||||||
ret.x = 0;
|
ret.x = 0;
|
||||||
if ( m_widget )
|
if ( m_widget )
|
||||||
{
|
{
|
||||||
GdkFont *font = m_font.GetInternalFont();
|
int width;
|
||||||
|
size_t count = GetCount();
|
||||||
wxCoord width;
|
|
||||||
size_t count = Number();
|
|
||||||
for ( size_t n = 0; n < count; n++ )
|
for ( size_t n = 0; n < count; n++ )
|
||||||
{
|
{
|
||||||
width = (wxCoord)gdk_string_width(font, wxGTK_CONV( GetString(n) ) );
|
GetTextExtent( GetString(n), &width, NULL, NULL, NULL, &m_font );
|
||||||
if ( width > ret.x )
|
if ( width > ret.x )
|
||||||
ret.x = width;
|
ret.x = width;
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user