Re: Plural forms: argument selection.



2006/7/28, Liam R E Quin <liam holoweb net>:

On Sat, 2006-07-22 at 12:54 +0100, Djihed Afifi wrote:

> Suppose the string:
> "There are %d files in directory %s".
>
> In arabic, for some plural forms, it would make more sense to omit %d
> and express it by words. By saying "more sense", I mean it would stand
> up as particularly inappropriate and inaccurate to include the number.
> Putting the number in parenthesis would be less than elegant.

There are other language problems with "%d files", one of which being
that
in Russian (as I recall) "files" needs to spelt differently for numbers
from 1 to 5... sort of like ordinals (1st, 2nd, 3rd, 4th etc.) in
English.

This should be solved by using ngettext() instead of gettext(). This
will give the translator the possibility to translate the string the
same amount of times as there are plural forms in the language.

It won't let you spell the actual *number* in a different way
though... not sure if that's what your asking for...

Isak



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]