[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [bug-gettext] Please do not set charset=GB2312 when using msginit --
From: |
Bruno Haible |
Subject: |
Re: [bug-gettext] Please do not set charset=GB2312 when using msginit --locale=zh_CN |
Date: |
Mon, 11 Mar 2019 00:22:51 +0100 |
User-agent: |
KMail/5.1.3 (Linux/4.4.0-141-generic; KDE/5.18.0; x86_64; ; ) |
Hi,
Boyuan Yang wrote:
> I am the team leader of TranslationProject (TP) Chinese (Simplified)
> translation team [1]. When working to convert POT files to PO files
> using msginit in order to initialise translation, I noticed that it
> will set the output PO file to be encoded using GB2312 [2].
>
> Example:
>
> 1. $ wget https://translationproject.org/POT-files/direvent-5.1.pot
> 2. $ msginit -l zh_CN -i direvent-5.1.pot -o a.po
GB2312 is indeed not adequate for today's needs; that's why everyone
who wants a Simplified Chinese locale nowadays uses the zh_CN.UTF-8
or zh_CN.GB18030 locale.
> If I do not explicitly specify "--locale=zh_CN", the generated file
> will be encoded in UTF-8.
This means that your current locale is likely zh_CN.UTF-8. This is the
value that you can give to the '-l' option.
I have updated the documentation of msginit to clarify that the locale
argument to give here may optionally include the encoding.
https://git.savannah.gnu.org/gitweb/?p=gettext.git;a=commitdiff;h=e267f7ff44162414596e47923aa6b2b74c8c581f
> Windows nowadays is also providing perfect support for UTF-8 texts.
This is not true: Windows does still not support an "ANSI" or "OEM"
code page that is UTF-8. Thus, program arguments (what you pass to
main()) and environment variables still don't support full UTF-8
across the board.
Bruno