HackerOne users: Testing against this community violates our program's Terms of Service and will result in your bounty being denied.
Plural forms problems
TiGR
✭
Plural function receives 3 arguments: number, single and plural form. There are 2 problems:
1. Some languages have more than 2 forms.
2. Some phrases with numerals are the same in english ("1 new" and "10 new").
2.1. And because of that Vanilla authors did not pluralize such phrases (quick tip: search for "%s new", there are three occurrences, and all of them are not plural and some of them even not translatable [no T() call]).
There are solutions for all of these problems, but maybe something could be done with Plural function itself to make it work better.
Currently possible solutions:
1. For third plural form use some kind of suffix (e.g., "_many")and add it to original string.
2. Make Plural function check if single form is the same as plural, and if they are, add another suffix.
2.1. Umm...
1. Some languages have more than 2 forms.
2. Some phrases with numerals are the same in english ("1 new" and "10 new").
2.1. And because of that Vanilla authors did not pluralize such phrases (quick tip: search for "%s new", there are three occurrences, and all of them are not plural and some of them even not translatable [no T() call]).
There are solutions for all of these problems, but maybe something could be done with Plural function itself to make it work better.
Currently possible solutions:
1. For third plural form use some kind of suffix (e.g., "_many")and add it to original string.
2. Make Plural function check if single form is the same as plural, and if they are, add another suffix.
2.1. Umm...
Tagged:
0
Comments
http://translate.sourceforge.net/wiki/l10n/pluralforms
Example plural translate for your language.
Dear S,
Please, tell me how can I resolve the same issue for Russian language?
You can see the differences here: localization-guide.readthedocs.org/en/latest/l10n/pluralforms.html