Hi, Thanks for your answers. On Sat, Jul 16, 2011 at 10:25:14AM +0200, Daniel Mustieles García wrote: > 2011/7/16 Johannes Schmid <jhs jsschmid de> > > > A lot of strings of the *.po are the same as in gedit. To avoid > > > retranslating them, for creating a *.po for a new language, I take the > > > *.po of gedit instead of creating a new one from the *.pot. Then I > > > update the *.po with the *.pot and I delete the commented strings (which > > > are present in gedit but not in latexila). Is it possible to do that > > > automatically? > > > > In general - don't do this. You never know if translation are really > > simular even if the original strings are. Better leave a comment and let > > the translator decide if he wants to reuse the strings. > > > > Translators can use their translation memory, son if the strings are the > same in both po files, the TM will help them/us. Don't worry about that :) OK, one problem solved :) > > > I think the easier is to use the autotools instead of CMake so it is > > > better integrated. But I'll need some information on how to handle the > > > XML file and the templates (*.tex). Is there a project with similar > > > needs? > > > > its-tool[1] seems the way to go nowadays. It does only handle xml AFAIK. > > > > There is also a tool called xml2po that can help you to get the .po file > from your xml files, but i think itstool is the best choice. > > > > [1] http://blogs.gnome.org/shaunm/2010/10/27/xml-translations-with-its/ > > OK. itstool seems very interesting. I'll try to use it with CMake. And if I succeed, I suppose it will be well integrated with Damned Lies (for the Mallard documentation, and for the other XML file). If I don't use gnome-doc-utils for the Mallard doc, I'll need to know how to install correctly the pages. The main problem I see is to open the documentation in the good language. With gedit for example, to open the documentation, it's simply the URI "ghelp:gedit". We don't have to specify the language nor the complete path. ===== One question remains: what about the templates (*.tex files)? Currently, each template is duplicated for each language. For example: article-en.tex, article-fr.tex, report-it.tex, etc. For all templates except the letter one, the unique change is to add one line (the babel package in most cases). For the letter template, it's more complicated because there are some strings to translate, and for some languages the template can be completely different (e.g. if another document class is used). So for the letter, it would be too complicated and not enough flexible if the template is decomposed into a lot of translatable strings. The letter template must be translated in "one block". It is possible to encode the templates as XML files. For the letter, it would be simply one big string to translate. For the other templates, there would be three blocks, but only the second block would be translatable (and would be empty in English). What do you think? Best regards, Sébastien
Attachment:
pgpP27b7XIdxk.pgp
Description: PGP signature