]> git.saurik.com Git - wxWidgets.git/blobdiff - src/msw/fontutil.cpp
Update bug in wxListCtrl,
[wxWidgets.git] / src / msw / fontutil.cpp
index 87acd8294992d15a880c3ce47a3ae5e4cc1d1019..ecaeb8e2bcb959cb7bf716626cf103c63b724624 100644 (file)
@@ -143,6 +143,10 @@ bool wxGetNativeFontEncoding(wxFontEncoding encoding,
         case wxFONTENCODING_CP1257:
             info->charset = BALTIC_CHARSET;
             break;
+
+        case wxFONTENCODING_CP874:
+            info->charset = THAI_CHARSET;
+            break;
 #endif // !Win16
 
         case wxFONTENCODING_CP437:
@@ -164,7 +168,7 @@ bool wxTestFontEncoding(const wxNativeEncodingInfo& info)
     wxZeroMemory(lf);       // all default values
 
     lf.lfCharSet = info.charset;
-    strncpy(lf.lfFaceName, info.facename, sizeof(lf.lfFaceName));
+    wxStrncpy(lf.lfFaceName, info.facename, sizeof(lf.lfFaceName));
 
     HFONT hfont = ::CreateFontIndirect(&lf);
     if ( !hfont )
@@ -425,6 +429,10 @@ wxFont wxCreateFontFromLogFont(const LOGFONT *logFont)
         case TURKISH_CHARSET:
             fontEncoding = wxFONTENCODING_CP1254;
             break;
+
+        case THAI_CHARSET:
+            fontEncoding = wxFONTENCODING_CP437;
+            break;
 #endif
 
         case OEM_CHARSET: