Difference between revisions of "Dev:Translation"

From Synfig Studio :: Documentation
Jump to: navigation, search
m (Translating synfig & synfigstudio: Added "make update-po", thanks to KiBi)
(add 64-bit workaround)
Line 17: Line 17:
 
== Testing ==
 
== Testing ==
  
To test your translation, save your po file as po/<languagecode>.po, edit configure.ac and add your language code to the ALL_LINGUAS variable. Once you have done that, do autoreconf and make install again. Then run synfigstudio or synfig to see how the translations look. If you edit the translation again, you just need to run make install again, no need to autoreconf.
+
To test your translation, save your po file as po/<languagecode>.po, edit configure.ac and add your language code to the ALL_LINGUAS variable (be sure that you are editing the one that is *before* AC_OUTPUT rather than adding a new one. Once you have done that, do autoreconf and make install again. Then run synfigstudio or synfig to see how the translations look. If you edit the translation again, you just need to run make install again, no need to autoreconf.
 +
 
 +
If you are on a 64-bit platform, then you might need to use this workaround to get synfig to produce and install the translation files:
 +
 
 +
make -C po all-yes ; sudo make -C po install-data-yes
 +
 
 +
Do this after doing a normal sudo make install, for both synfig and synfigstudio.
  
 
== Contributing ==
 
== Contributing ==
  
 
When your translation is satisfactory or you have an update to it, open a patch in the sf.net bug/patch tracker and we will add it to SVN.
 
When your translation is satisfactory or you have an update to it, open a patch in the sf.net bug/patch tracker and we will add it to SVN.

Revision as of 00:09, 20 November 2007

Translating synfig & synfigstudio

synfig and synfigstudio are now translatable. We are using the standard gettext system and .po files. The gettext manual has lots of good advice for translators and programmers alike.
When you are building the source, the build system will create a PO Template for both synfig (po/synfig.pot) and synfigstudio (po/synfigstudio.pot). If those files are missing, run "make update-po" in the po/ directories.
To start a new translation, you can get into the po directory and run msginit, which will determine the correct language code from your environment, ask for your email address and create <languagecode>.po, which you should edit with one of the tools mentioned below.

We are currently auditing the code for translatable strings, so more strings will appear for translation over time.

Editing tools

Any text editor (notepad/textedit/gedit/vi/emacs) will do (especially those with specific modes for PO files), but there are a few GUI tools that make the process easier for translators by integrating spell checking, dictionaries and so on:

  • KBabel: A KDE/Qt translation tool
  • Pootling: A cross-platform tool with some nice features
  • gtranslator: a somewhat older tool for GNOME

Testing

To test your translation, save your po file as po/<languagecode>.po, edit configure.ac and add your language code to the ALL_LINGUAS variable (be sure that you are editing the one that is *before* AC_OUTPUT rather than adding a new one. Once you have done that, do autoreconf and make install again. Then run synfigstudio or synfig to see how the translations look. If you edit the translation again, you just need to run make install again, no need to autoreconf.

If you are on a 64-bit platform, then you might need to use this workaround to get synfig to produce and install the translation files:

make -C po all-yes ; sudo make -C po install-data-yes

Do this after doing a normal sudo make install, for both synfig and synfigstudio.

Contributing

When your translation is satisfactory or you have an update to it, open a patch in the sf.net bug/patch tracker and we will add it to SVN.