UTF-8 in Windows

前端 未结 4 1399
别那么骄傲
别那么骄傲 2020-12-09 08:21

How do I set the code page to UTF-8 in a C Windows program?

I have a third party library that uses fopen to open files. I can use wcstombs to convert my Unicode fi

4条回答
  •  死守一世寂寞
    2020-12-09 09:19

    Use cygwin (which provides a UTF-8 locale by default), or write your own libc hack for Windows that does the necessary UTF-8 to UTF-16 translations and wraps the nonstandard _wfopen etc. functions.

提交回复
热议问题