Translations, translations, translations

Dirk Hohndel dirk at
Sun Oct 21 10:21:32 PDT 2012

On Oct 21, 2012, at 9:30 AM, Dirk Hohndel wrote:

>> I think you have made a mistake in trying to translate some of libdivecomputer.c
>> Translating some of those things based on locale is *wrong*, because
>> they are saved in the XML file.

Thinking about this some more, what this means is that we need to separate
what is stored and what is displayed. We should STILL translate the texts that
are being displayed on screen - but we should store ONLY the English strings
in the XML file.

The logic for this should be straight forward - I'll take a stab at implementing this
later today. Sadly I guess this will prevent me from releasing 2.1 today (unless
the change is truly trivial).

We'll see.

>> That covers at least the warnings: they'll get translated when you
>> import them, and then saved to the XML file as that translation, but
>> now if you start subsurface in another locale, they will not get
>> translated back.
>> So translating XML file contents is fundamentally buggy. It just
>> shouldn't be done.
>> So all the "translations" for the event handling are buggy, and
>> generate crap. Please don't do that. Leave them as English.
> You are of course correct. I thought those were the texts shown in the profile as warnings

They are. And that's why we want to translate them

> We definitely don't want to translate tags and properties that go in the XML.

And that is of course correct as well.

I think a BETTER solution would have been not to store the texts but just
a token or enum or something, but it is what it is, I'm not changing the file
format at this stage.

As I said above, I'll store the English texts but display translated versions.


More information about the subsurface mailing list