[Python-Dev] Translating sample programs in documentation
fromwheretowhere.service at gmail.com
Sun Apr 15 12:41:16 EDT 2018
Excuse me if this was discussed before, but in French and Japanese
translations, all the sample programs seem to have identifiers in
English still. According to "PEP 545 -- Python Documentation
Translations", as I understand .po files are used for translations. May
I ask if there's technical restrictions causing translations being only
applied to the text parts?
For example, here's the first sample program in 4.2:
>>># Measure some strings:
... words = ['cat', 'window', 'defenestrate']
>>>for w in words:
... print(w, len(w))
Here's a possible translation in Chinese:
>>> # 丈量一些字符串
... 词表 = ['猫', '窗户', '丢出窗户']
>>> for 词 in 词表:
... print(词, len(词))
As you may notice the strings differ in size if they are translated
directly. Obviously that does add extra burden to review the new sample
programs to assure effectiveness and readability.
Any suggestion or comments are welcome.
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the Python-Dev