support for unicode font names

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@37956 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Stefan Csomor 2006-03-10 15:59:52 +00:00
parent 71771e3525
commit b6b59e43ca

View File

@ -88,7 +88,6 @@ bool wxFontEnumeratorHelper::SetEncoding(wxFontEncoding encoding)
void wxFontEnumeratorHelper::DoEnumerate()
{
MenuHandle menu;
Str255 p_name;
short lines;
menu = NewMenu( 32000, "\pFont" );
@ -97,8 +96,19 @@ void wxFontEnumeratorHelper::DoEnumerate()
for ( int i = 1; i < lines + 1; i ++ )
{
wxString c_name ;
#if TARGET_API_MAC_CARBON
CFStringRef menutext ;
c_name = wxEmptyString ;
if ( CopyMenuItemTextAsCFString (menu, i, &menutext) == noErr )
{
c_name = wxMacCFStringHolder(menutext).AsString(wxLocale::GetSystemEncoding());
}
#else
Str255 p_name;
GetMenuItemText( menu, i, p_name );
wxString c_name = wxMacMakeStringFromPascal( p_name );
c_name = wxMacMakeStringFromPascal( p_name );
#endif
#if 0
if ( m_fixedOnly )