bug-gnu-utils
[Top][All Lists]
Advanced

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

Re: [Traduc] Question regarding an error with msgfmt


From: Bruno Haible
Subject: Re: [Traduc] Question regarding an error with msgfmt
Date: Sun, 25 Jan 2009 22:36:24 +0100
User-agent: KMail/1.9.9

Claude Paroz wrote:
> I've seen in the past the use of '%0d' to workaround the need to put the
> specifier when the translator doesn't like/need to use it (I don't have
> a valid use case at hand just now). What's your opinion about this ?

It's a bad hack that more often than not will produce wrong translations.
Namely, most often the translator thinks that msgstr[0] applies only to
n==1. In the new section I have described why this is often not the case.

With older versions of msgfmt this hack could be needed in rare corner-cases.
For example when you knew that the value was in the range 1..15, and the
plural form applies to the values 1,21,31,41,... then you know that the
value is 1, and you can write "one" instead of "%d". But msgfmt did not
know that. - The good news is that in the next gettext release, the
programmer will have a way to tell msgfmt that the value is in the range 1..15.

> This reminds me of a discussion we had in gnome-i18n about languages
> with no plural. Here's the resulting blog post:
> http://runab.livejournal.com/18927.html

The fact that you may have to remove msgstr[1] from the PO file in this
case is something you can infer from the text I posted.

The fact that the more important string is msgid_plural is also clear,
I hope.

Bruno




reply via email to

[Prev in Thread] Current Thread [Next in Thread]