2009/6/11 Yuki KODAMA <[email protected]>

> On Thu, Jun 11, 2009 at 6:13 PM, Peer
> Sommerlund<[email protected]> wrote:
> >
> >
> > 2009/6/11 Yuki KODAMA <[email protected]>
> >>
> >> Hi,
> >>
> >> This is a topic related i18n.
> >> When I use GTK+ standard components, such as 'OK' & 'Close' buttons,
> >> 'About' dialog, I realized those labels doesn't translate to specified
> >> language.
> >> On the other hand, when I launched THG from source, it was translated
> >> correctly. Since the latter uses pygtk library (installed by me) in my
> >> python
> >> install directory, it has translation files for GTK+ standard components
> >> (share/locale directory).
> >>
> >> To fill missing translation files, I copied all .mo files in GTK+
> >> directory to
> >> TortoiseHg's GTK+ directory, but it doesn't work I expected.
> >>
> >> Any idea or hint?
> >
> > I know very little about gettext but from the API you get the impression
> > that you can specify the location of compiled domain files (like
> gtk20.mo)
> > 1) Did you place the gtk20.mo (and related) files in the same folder as
> the
> > tortosiehg.mo file?
> > 2) Maybe GTK has some default location it uses to find .mo files, like
> > %GTK_BASEPATH%/share/locale  -- maybe setting this environment variable
> > would help.
> > Regards,
> > Peer
>
> Your point of view (2) was very helpful. Thanks.
> It was translated correctly by putting .mo files of GTK+ to TortoiseHg's
> '%THG%/gtk/share/locale/LANG/LC_MESSAGES' directory.
> Not same directory with 'tortoisehg.mo' file. But I don't know whether
> 'gtk20.mo' file is enough.
>
> directory structure (%THG% is install directory):
>
> '- %THG%
>   |- locale
>   |  '- ja
>   |     '- LC_MESSAGES
>   |        |- hg.mo
>   |        '- tortoisehg.mo
>   |- gtk
>   |  '- share
>   |     '- locale
>   |        '- ja
>   |           '- LC_MESSAGES
>   |              '- gtk20.mo
>   |- hgtk.exe
>   |- library.zip
>   |
>   |  (snip)
>   |
>   |- hg.exe
>   '- i18n
>
> Could you include GTK+ .mo file(s) to your 'thg-installer' project?
>

My GTK installation have .mo files for 106 languages. This would increase
the installer size with 18M byte - do we want to include all of this just
for a few button lables?

Until we have a better solution I propose that we do it for locales "ja" and
"it" where we have full translations. Each language contributes with about
100k - 200k byte of .mo files from GTK.

What is the thg-develop list opinions on this?

Since the thg-installer currently depends on manualy copy of GTK files,
Steve would have to do this in his build environment.


In the future we might want to distribute .mo files separately so instead of
installing 100 languages you just install your own language.

Another aproach would be to find a way to detect a local GTK installation
and use the .mo files found there. On the other hand, this opens issues with
different versions of GTK.

Regards,
Peer
------------------------------------------------------------------------------
Crystal Reports - New Free Runtime and 30 Day Trial
Check out the new simplified licensing option that enables unlimited
royalty-free distribution of the report engine for externally facing 
server and web deployment.
http://p.sf.net/sfu/businessobjects
_______________________________________________
Tortoisehg-develop mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/tortoisehg-develop

Reply via email to