more DBCS-related changes (patch 481898)

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@12528 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Vadim Zeitlin
2001-11-20 18:49:51 +00:00
parent 7ecb8b06ad
commit c7821f944f
2 changed files with 42 additions and 3 deletions

View File

@@ -1295,11 +1295,31 @@ wxFontEncoding wxLocale::GetSystemEncoding()
#ifdef __WIN32__
UINT codepage = ::GetACP();
// wxWindows only knows about CP1250-1257
// wxWindows only knows about CP1250-1257, 932, 936, 949, 950
if ( codepage >= 1250 && codepage <= 1257 )
{
return (wxFontEncoding)(wxFONTENCODING_CP1250 + codepage - 1250);
}
if ( codepage == 932 )
{
return wxFONTENCODING_CP932;
}
if ( codepage == 936 )
{
return wxFONTENCODING_CP936;
}
if ( codepage == 949 )
{
return wxFONTENCODING_CP949;
}
if ( codepage == 950 )
{
return wxFONTENCODING_CP950;
}
#elif defined(__UNIX_LIKE__) && wxUSE_FONTMAP
wxString encname = GetSystemEncodingName();
if ( !encname.empty() )