citiususc / calendula

An Android assistant for personal medication management
https://citius.usc.es/calendula/
GNU General Public License v3.0
208 stars 107 forks source link

Plural strings and variables, usage of CLDR #169

Open yarons opened 5 years ago

yarons commented 5 years ago

https://github.com/citiususc/calendula/blob/eff75857bccb8040d166f73e875c2c984f7112aa/Calendula/src/main/res/values/strings_translatable.xml#L527-L539

These strings should be handled like the other plurals but also with an argument (%d day, %d days).

The reason for it is that the placement of the variable is different in Hebrew (Single day is usually not counted, 2 days is a single word, starting from 3 days there's a number before the plural form of the expression "day" in Hebrew).

In Arabic it's much more complicated but based on the same principals.

EDIT: Also, there's an option to use CLDR instead of asking the translators to translate the days of the week, etc.