[Qgis-community-team] doing translation using OSX

Paolo Corti pcorti at gmail.com
Thu Jun 21 09:11:35 PDT 2012


Hi Diethard

>
> I found that I had to install gettext additionally to create mo.files from
> po.files. I followed instructions
> from http://www.rmnl.net/read-about/installing-gettext-snow-leopard-django/
>

yes, gettext is needed on linux as well, but I guess almost any
distribution already includes it as it is being used extensively by
many software.

> For mac make compile_messages unfortunately does not work because the osx
> find-command does not understand the printf argument that is used to remove
> path from the full filename.
>
> Instead I had to use something like:
> msgfmt source/translated/nl/preamble.po -o
> source/translated/nl/LC_MESSAGES/preamble.mo
>

I do not understand what you mean exactly.
In any case the Sphinx Makefile is customized, so you can compile all
the messages, without bothering, simply with:

$ make compile_messages

> Next I continued to translated preamble using Qlinguist, which works fine.
> However sometimes you have to restructure the rst document for the language
> as well.
> For example to give credits for the ones who have helped to translate the
> document there is a need to add an additional table below the authors table.
> This can not be done using Qlinguist.
> So I propose that  in every language tree there should be the possibility to
> create rst documents that can be changed a little bit. During the build
> these should override the main rst documents. Ofcourse the contents of the
> rst documents should not be translated!

I don't see a way an easy way to maintain two master copy as it would
be required by this structure.
Let's say we have the preamble.rst master document and a copy of it
just for your language: when someone will change the original
preamble.rst document, you would need to manually update your local
copy (and then the .pot and .po files).

I think it would be more convenient then not to use the Sphinx
internationalization support then, but just translate the rst
documents.
What about adding a page in the master copy for this purpose, without
complicating too much the structure? (local credits and so on...)

>
> What I also miss now is the possibility to include the localized
> screenshots.

This can be already done (should be written in the readme, though, you
are right): each directory should have an img directory for each
language, where to put the localized ones.
Then the translator in the .po file will need to update the link (from
img/en/whatever.gif to img/fr/whatever.gif)

Hope is clear
cheers
p

-- 
Paolo Corti
Geospatial software developer
web: http://www.paolocorti.net
twitter: @capooti
skype: capooti


More information about the Qgis-community-team mailing list