Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

建议转换成UTF-8编码 #1

Open
librehat opened this issue Jul 24, 2015 · 4 comments
Open

建议转换成UTF-8编码 #1

librehat opened this issue Jul 24, 2015 · 4 comments

Comments

@librehat
Copy link

目前的编码是GBK,在Linux下默认字符集是UTF-8,输出的中文都是乱码(我就试了一下联赛引擎)。用iconv转换成UTF-8之后重新编译即可正常输出中文。

建议通过类似的脚本批量转换成UTF-8字符集,以处理多平台的中文乱码问题

for file in *.cpp
do
    iconv -f GBK -t UTF-8 -o "${file}.new" "${file}" && mv -f "${file}.new" "${file}"
done
@auntyellow
Copy link
Member

因为当中包含GBK和BIG5的字符用来显示走法(主要是cchess/cchess.cpp),目前还不能换成UTF-8,敬请谅解。

@librehat
Copy link
Author

那联赛引擎应该可以转换吧,LEAGUE目录下的

@auntyellow
Copy link
Member

这个你转一下试试看吧

@auntyellow auntyellow reopened this Nov 4, 2020
@calcitem
Copy link

考虑把GBK和BIG5的字符抽离到单独文件中来定义?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants