On Sun, May 11, 2014 at 10:58 AM, Thiago Macieira <[email protected]> wrote:
> Em dom 11 maio 2014, às 10:00:38, Tomaz Canabrava escreveu:
>> > I don't mind the cleanup, but I dislike the fact that you break things.
>> > The reason I did the stupid hackish thing with the translations for the
>> > hemispheres was that I needed them to be in the correct class. For some
>> > reason if they were not part of MainTab the correct translations were
>> > not picked up and parsing of local language hemisphere letters was
>> > broken.
>>
>> What? Well, sorry for that, the commit message on the hackish code didn't
>> explained that, and I don't know why it does that. Thiago, you know the tr
>> code a but more than I do, what could be wrong?
>
> When I looked at Dirk's change, it seemed that the hemispheres were not
> translated at all previously. Now that I look at it, I've found them:
>
> qt-ui/maintab.cpp:      lath = lat >= 0 ? tr("N") : tr("S");
> qt-ui/maintab.cpp:      lonh = lon >= 0 ? tr("E") : tr("W");
>
> So the translations belong to MainTab. To get them from outside that class,
> you either do what Dirk did (making its tr accessible publicly) or you do:
>
>         QCoreApplication::translate("MainTab", "N");

That will not work for what I want, that is to get rid of the
necessity of the QtGUI on non QtGui code.
I think that if the translations are a issue there we should create a
north(); south(); east(); west(); functions
that returns the translated version of the string. Even if we need to
retranslate those strings on transifex.

Unless we don't need an app that's divided into smaller libs ( but's
that way easier to test in an automated way. )

Tomaz.

>
> --
> Thiago Macieira - thiago (AT) macieira.info - thiago (AT) kde.org
>    Software Architect - Intel Open Source Technology Center
>       PGP/GPG: 0x6EF45358; fingerprint:
>       E067 918B B660 DBD1 105C  966C 33F5 F005 6EF4 5358
>
> _______________________________________________
> subsurface mailing list
> [email protected]
> http://lists.hohndel.org/cgi-bin/mailman/listinfo/subsurface
_______________________________________________
subsurface mailing list
[email protected]
http://lists.hohndel.org/cgi-bin/mailman/listinfo/subsurface

Reply via email to