[virt-tools-list] [libosinfo 3/5] Mark obvious strings in DB for translation

Michal Privoznik mprivozn at redhat.com
Fri Oct 19 13:38:04 UTC 2012


On 19.10.2012 15:24, Zeeshan Ali (Khattak) wrote:
> On Fri, Oct 19, 2012 at 4:19 PM, Zeeshan Ali (Khattak)
> <zeeshanak at gnome.org> wrote:
>> On Fri, Oct 19, 2012 at 1:15 PM, Christophe Fergeau <cfergeau at redhat.com> wrote:
>>> On Fri, Oct 19, 2012 at 11:56:37AM +0200, Michal Privoznik wrote:
>>>> Or, are you trying to allow translation of XML element values? Again,
>>>> translating CentOS is not a good idea. I cannot even imagine situation
>>>> where this is needed.
>>>
>>> Yes, the goal is to translate the element content. It's nice at least for
>>> Windows versions which have localized names for their different editions:
>>> http://windows.microsoft.com/fr-FR/windows7/products/compare
>>> Now that you mention it, marking every single name as translatable is
>>> probably overkill (unless in some languages, they transliterate the names
>>> in the script they are using?)
>>
>> Yes, thats exactly the point. Think global, not western-only. :) Here
>> you see information about Microsoft and Windows in Arabic:
>>
>> http://ar.wikipedia.org/wiki/%D9%85%D8%A7%D9%8A%D9%83%D8%B1%D9%88%D8%B3%D9%88%D9%81%D8%AA
>> . "مايكروسوفت" is simply Microsoft but in arabic script.
>> http://ar.wikipedia.org/wiki/%D9%85%D8%A7%D9%8A%D9%83%D8%B1%D9%88%D8%B3%D9%88%D9%81%D8%AA_%D9%88%D9%8A%D9%86%D8%AF%D9%88%D8%B2
> 
> Even better example is the Farsi page for windows:
> 
> http://fa.wikipedia.org/wiki/%D9%85%D8%A7%DB%8C%DA%A9%D8%B1%D9%88%D8%B3%D8%A7%D9%81%D8%AA_%D9%88%DB%8C%D9%86%D8%AF%D9%88%D8%B2
> 
> They are also translating numbers: "ویندوز ۲۰۰۰" is Windows 2000.
> 

I still don't think this is a good idea. What if an application wants to
dump info about Microsoft Windows? I mean, it is enforced to translate
the name otherwise it won't find anything.

The biggest question is: are <name/>, <version/> and <vendor/> sort of
ID or not? If it is so, then we cannot translate it; if they are not an
ID, then we can translate it, wisely.

My biggest concern is to not force libosinfo consumers to change
anything (esp. in non-easily-solvable way -> translating Windows from
Farsi to English). But on the other hand, our consumers can set locale
before they link with libosinfo, right? I mean:

  setlocale();
  dlopen();

Which sucks really, doesn't it?

So maybe, if libosinfo would implement a function to enable localization
(and eventually set one)? That would leave both sides happy, right?

Michal




More information about the virt-tools-list mailing list