[Paraview-developers] Paraview translation to another languages

Utkarsh Ayachit utkarsh.ayachit at kitware.com
Thu Feb 16 11:09:23 EST 2017


Shagit,

I must admit I have never looked into anything related to
internationalization. With my limited understanding of this, they way I see
it is there are two parts:

1. generate the translation that maps string A to translated string B.
2. make sure the application, before showing the string in the UI, does a
lookup through the translation table via QObject::tr().

What I explained (or hoping to address) was (2). For (1), you'll have to
manually (or via tool) process the xmls in ParaView to extract labels and
documentation texts to determine the phrases that need to be translated (1).

Hope that helps, but I hope someone more familiar with internationalization
can chime in.

Utkarsh

On Thu, Feb 16, 2017 at 10:56 AM, Шагит Зиганшин <zig.shagit at ya.ru> wrote:

> Utkarsh,
>
> I really don't understand how to use default Qt translation tools, like
> lupdate and lrelease, with non-source files (XML in our case). Things like
> QT_TRANSLATE_NOOP wont work I think.
>
> I always thought lupdate parsing source code and seeking strings marked
> with tr(), so I don't know how fixing pqProxyWidget will help us to
> implementing localization.
>
> If I'm wrong, please correct me!
>
> Shagit Ziganshin
>
>
> 16.02.2017, 17:18, "Utkarsh Ayachit" <utkarsh.ayachit at kitware.com>:
>
> Shagit,
>
> I believe a lot of the code that shows labels from XML on the UI doesn't
> go through QObject::tr() currently. The first step would be fix all of that
> to use tr(). A starting point will be pqProxyWidget.
>
> Utkarsh
>
> On Thu, Feb 16, 2017 at 4:35 AM, Shagit Ziganshin <zig.shagit at ya.ru>
> wrote:
>
> Hello!
>
> I want to implement in Paraview localization to other languages by using
> the translation module of Qt. But I found the problem that some widgets are
> declared in XML and have no idea how to implement them in translation
> functions (like QObject::tr). Can anyone suggest ways to get around these
> limitations? Or is it impossible in theory?
>
> Shagit Ziganshin
> _______________________________________________
> Powered by www.kitware.com
>
> Visit other Kitware open-source projects at http://www.kitware.com/opensou
> rce/opensource.html
>
> Search the list archives at: http://markmail.org/search/?q=
> Paraview-developers
>
> Follow this link to subscribe/unsubscribe:
> http://public.kitware.com/mailman/listinfo/paraview-developers
>
>
>
>
> Шагит Зиганшин
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://public.kitware.com/pipermail/paraview-developers/attachments/20170216/8e68c52e/attachment.html>


More information about the Paraview-developers mailing list