Re: translation context handling in vdr >= 1.5.7

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

 



Klaus Schmidinger wrote:
> On 08/23/07 13:48, Christian Wieninger wrote:
>> Hi,
>>
>> I just noticed a small change in the context handling of translations 
>> since vdr-1.5.7. Till now it was possible to have e.g.
>>
>> const char AllowedChars[] = trNOOP("$ 
>> abcdefghijklmnopqrstuvwxyz0123456789-.,#~\\^$[]|()*+?{}/:%@&");
>>
>> Note the 2 '$'. The first one only helps to have the second one in the 
>> translation and not to be interpreted as context.
>>
>> Previous implementations of I18nTranslate did only cut the context of 
>> the english version. So the translation could look like this in i18n.c 
>> or the po-files:
>>
>>    // The allowed characters in strings:
>>    { "$ abcdefghijklmnopqrstuvwxyz0123456789-.,#~\\^$[]|()*+?{}/:%@&",
>>      " aäbcdefghijklmnoöpqrsßtuüvwxyz0123456789-.,#~\\^$[]|()*+?{}/:%@&",
>>      " abcdefghijklmnopqrstuvwxyz0123456789-.,#~\\^$[]|()*+?{}/:%@&",
>> ...
>>
>> The current implementation cuts the translations too which results in
>>
>> "[]|()*+?{}/:%@&"
>>
>> Is this intended? If so, one could add the dummy '$' also at the 
>> beginning of the translation, but has to handle this again for backwards 
>> compatibility.
>>
>> If it's not intended the following patch should give the previous behaviour:
[...]
> 
> gettext() may or may not return the original string, so if no translation
> is found, the context needs to be stripped.
[...]

For the record, gettext also has context support:
http://www.gnu.org/software/gettext/manual/gettext.html#Contexts

But if it needs too many changes, maybe it is not worth it.

-- 
Anssi Hannula

_______________________________________________
vdr mailing list
vdr@xxxxxxxxxxx
http://www.linuxtv.org/cgi-bin/mailman/listinfo/vdr


[Index of Archives]     [Linux Media]     [Asterisk]     [DCCP]     [Netdev]     [Xorg]     [Util Linux NG]     [Xfree86]     [Big List of Linux Books]     [Fedora Users]     [Fedora Women]     [ALSA Devel]     [Linux USB]

  Powered by Linux