glob2-devel
[Top][All Lists]
Advanced

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

Re: [glob2-devel] localization


From: Fernando J. Rodríguez (Herr Groucho)
Subject: Re: [glob2-devel] localization
Date: Mon, 23 Jan 2006 17:14:51 -0300
User-agent: KMail/1.7.2

El Lun 23 Ene 2006 11:14, Matthew Marshall escribió:
> On Monday 23 January 2006 08:05, Stéphane Magnenat wrote:
> > I want to keep the fallback, because otherwise a release can be
> > blocked by missing translations.
>
> I think that what Leo was saying is to have a _blank_ translation
> be a fallback.  (Not only a missing translation.)

There's another issue: sometimes a translation *should* be empty.
So I think the best behaviour is this:
1) If there is a translation defined in an texts.XX.txt file, use it, 
even if it is empty.
2) If there is a missing translation, use the English one as a 
fallback.

The difference with the current behaviuor is that currently a defined 
but empty translation is not used, but instead the English fallback 
is.

An example follows:
texts.en.txt:
[1]
one
[2]
two
[3]
three

texts.es.txt:
[1]
uno
[2]


When looking for a Spanish translation for [1], "uno" should be used, 
because it exists in texts.es.txt. When looking for a translation for 
[2], an empty string should be used, because [2] exists in 
texts.es.txt even thought it is defined as an empty string. Finally, 
when looking for a translation for [3], "three" should be used, 
because [3] is not defined and so, the fallback mecanisim should take 
place.


It happened to me that I wanted to translate a sentece the game 
displays by concatenating a few strings that one of the strings 
needed to be empty, however, I couldn't do that because the game 
instead displayed the English translation for that string. Of course 
I could do ugly-looking things like putting a space instead of an 
empty string but I shouldn't.

I think it was the "of which n are looking for a job" thing, which is 
a sentence the game builds by concatenating "of which", the number, 
and "looking for a job".
I can translate it into Spanish as:
"of which" -> de los cuales
"looking for a job" -> están buscando trabajo

...to make up the sentence like: "de los cuales n están buscando 
trabajo". However, an alternate, valid expression of that sentence is 
"n de los cuales están buscando trabajo", which I could get if I 
translated:
"of which" -> (empty string)
"looking for a job" -> de los cuales están buscando trabajo

In spite of my intentions, the game would display this:
"of which n de los cuales están buscando trabajo".
The bottom line is: "There meed to be a way of distinguish an empty 
translation from an undone translation".


Perhaps a more translator-friendly way of organizing the translatable 
strings might be in this case:

[of which %d are looking for a job]

and let the translator translate the whole sentence, for one cannot 
asume that all languages will have some text, the number, and a 
little more text as a translation of "of which n are looking for a 
job". It would requiere to repeat "of wich" in some 2 or 3 places, 
but I consider it a feature, as there are languages in which "of 
which" is translated differently acording to context, grammatical 
gender and grammatical number. Spanish is one such language, and I 
was just lucky that "trabajador" (worker) and "guerrero" (warrior) 
are both masculine, so the same "de los cuales" can work for both. 
But if one of "trabajador" or "guerrero" were femenine, I would have 
needed to translate "of which" as "de las cuales" in one case, and 
"de los cuales" in the other which, in the current organization os 
strings, is not possible.

I can look for cases of yuxtapositioning of translatable strings in 
the code and convert them to whole sentence strings like the above, 
but it would render all translations not up-to-date.

Please advice.

-- 
Herr Groucho

ID Jabber: address@hidden
Señal distintiva: LU5MJR - 144,550 MHz FM.
Clave pública GPG: hkp://pks.lugmen.org.ar
Fingerprint GPG: B7BD 0FC7 D9A2 66F3 4EFC  45EE 7DE2 3932 597B 6354




reply via email to

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