make pot broken? was: Updates for Latvian po file

Christian Stimming stimming at tuhh.de
Fri Jun 25 14:34:16 EDT 2010


Am Thursday 24 June 2010 schrieb Valdis Vītoliņš:
> > From src/app-utils/gnc-ui-util.c 656ff:
> >         /* Translators: For the following strings, the single letters
> >            after the colon are abbreviations of the word before the
> >            colon. You should only translate the letter *after* the colon.
> >            */
> >     
> >     case NREC:
> >         return string_after_colon(_("not cleared:n"));
> 
> I corrected this.
> 
> > Valdis, you should never translate the part before the colon.
> 
> Hm.. This statement seems too wide. There are number of field labels

Both of you are correct. Frank was referring to these particular strings from 
gnc-ui-util.c, where the comments in the source code were intended to be read 
by the translator. Unfortunately, somehow we forgot to put the comments in the 
correct line which prevented them from showing up in gnucash.pot (I fixed this 
a minute ago). These comment sentences should have appeared in your lv.po so 
that you, the translator, should have seen this advice, and should have been 
able to not translate the part in front of the colon.

In any case, we all agree this is an old clumsy way of translating the 
abbreviation, but that's the only way that was available 10 years ago when 
this code was written, and it hasn't been touched since then. Today, we would 
rather implement this using the new pgettext() function with an extra context 
string, like so: pgettext("account status: not cleared", "n"); which results 
in a msgid like so:

#: src/app-utils/gnc-ui-util.c:656
msgctxt "account status: not cleared"
msgid "n"
msgstr ""

> and messages with colon in form ...: %s,
> which seems to be translatable. (I compared by searching strings for
> en_GB.po and de.po)

You are right. All other strings in the po file with some colons in there 
should be translated completely.

> Though I found that there are strings with sample:... where sample:
> should not be translated.

This is correct as well, but not very important, because those strings are 
only used to estimate a text field width - the strings itself are never shown 
to the user in any case.

> BTW, I found that translated po files are quite different and seems
> updated last time in quite different versions.
> Where is lost po template (*.pot) file, or which other file is master
> copy?

There is no master copy of a *.pot file! There is only the gnucash source 
code, which you can download and prepare for compiling, and then call "make 
pot" to have the most up-to-date gnucash.pot created for you.

Apart from that, each gnucash.tar.gz source package contains one gnucash.pot 
which was most up-to-date at the time of packaging that particular source 
package. You can use that as well.

Best Regards,

Christian


More information about the gnucash-devel mailing list