Difference between revisions of "Documentation translation"
(→Tutorial Translation: Point to the po files.) |
|||
| (8 intermediate revisions by 4 users not shown) | |||
| Line 10: | Line 10: | ||
* Each tutorial is in its own subdirectory. You need the <code><LANG>.po</code> file, for example <code>basic/fr.po</code>. Please coordinate with the previous translator listed in that file! | * Each tutorial is in its own subdirectory. You need the <code><LANG>.po</code> file, for example <code>basic/fr.po</code>. Please coordinate with the previous translator listed in that file! | ||
* If there is none of these files, get the <code><tutorial>.pot</code> file, rename it to <code><LANG>.po</code> and start translating. | * If there is none of these files, get the <code><tutorial>.pot</code> file, rename it to <code><LANG>.po</code> and start translating. | ||
Once you are satisfied with what you have done, submit it to the | Once you are satisfied with what you have done, submit it to the Launchpad bug tracker. Open a new bug with name translation to <your language>, upload the po-file there as attachment. You need to create an account on ubuntu launchpad if you have no account there, yet. | ||
Thanks! | Thanks! | ||
= Keyboard and mouse translation = | When adding a new tutorial SVG to the SVN ([http://inkscape.svn.sourceforge.net/viewvc/inkscape/inkscape/trunk/share/tutorials/ to the tutorial directory]), it's recommended to also perform the following steps: | ||
* Add the filename of the tutorial SVG (and any additional files it needs, like PNG images referenced from the SVG) to '''share/tutorials/Makefile.am''' in the [http://inkscape.svn.sourceforge.net/viewvc/inkscape/inkscape/trunk/ main inkscape trunk]. | |||
* If the SVG refers to a PNG, then that PNG should exist in the SVG's directory -- make sure to also commit that PNG. | |||
* Modify the translation of the tutorial filename in the main PO file so as to make Inkscape display the localized tutorial instead of the default (English) one. An example: if the <code>"tutorial-basic.svg"</code> string is translated the following way in '''po/fr.po''' | |||
:<code>msgid "tutorial-basic.svg"</code> | |||
:<code>msgstr "tutorial-basic.fr.svg"</code> | |||
:then whenever the locale is French, Inkscape will display the French (and not the default English) basic tutorial for users. | |||
* Update the [[TranslationStatus | translation status]] in the wiki. | |||
You may also check the tutorials with the [http://inkscape.svn.sourceforge.net/viewvc/inkscape/inkscape/trunk/po/check_for_tutorial_problems.sh?view=log check_for_tutorial_problems.sh] script. See the comments inside the script for more information. | |||
== Verification == | |||
To create up-to-date tutorials (the '''tutorial-*.svg''' files), you'll need to build | |||
them from the tutorial PO files. Here's how to do it: | |||
# Install Saxon 6.5.x (Saxon is a tool that converts XML to SVG using XSLT, see [http://saxon.sf.net saxon.sf.net]) if it's not already installed. You can install it with your package manager or by downloading the appropriate file from the Saxon homepage and unzipping it into a suitable directory. You need to install version 6.5.x -- the build process doesn't work with newer versions. E.g. under openSUSE, install '''saxon-6.5.5''' or a similarly named package -- NOT '''saxon8''' or similar. The build scripts need to find '''saxon.jar''' in your Java classpath -- you may want to check your classpath in case of a Java problem. | |||
# Install Java SDK (JRE is not enough) if it's not already installed. Under openSUSE, the package name should be '''java-1_6_0-sun-devel''' or something similar. You can check your installation with <pre>type java</pre> from the command line -- check that '''java''' actually points to the SDK's '''java''' executable that you installed. | |||
# Update your local copy of the [http://inkscape.svn.sourceforge.net/viewvc/inkscape/doc-docbook/trunk/ docbook trunk] and the [http://inkscape.svn.sourceforge.net/viewvc/inkscape/inkscape/trunk/ main inkscape trunk] from SVN. | |||
# <pre>cd doc-docbook/javaclasses/org/inkscape/xslt; javac files.java</pre> ('''doc-docbook/''' being the root of your local copy of the docbook trunk) (this rebuilds '''files.class''', which is a Java class file) | |||
# <pre>cd doc-docbook/</pre> ('''doc-docbook/''' being the root of your local copy of the docbook trunk) | |||
# <pre>make svg</pre> (this creates all tutorial SVGs for all languages -- can take long) | |||
# Check the newly created tutorial SVGs (which you'll find in their specific tutorial directories: '''advanced/''', '''basic/''', ...) for overlapping text (often caused by font settings) and other problems. It's recommended to perform the check under a different operating system. If the SVGs have overlapping text, check the default fonts on your computer. | |||
# If you want to commit the newly created tutorial SVGs, then copy the new '''tutorial-*.svg''' files to the '''share/tutorials/''' directory of your local copy of the main inkscape trunk and commit them to the main inkscape trunk. | |||
For more information, see '''doc-docbook/README''' (WebSVN version [http://inkscape.svn.sourceforge.net/viewvc/inkscape/doc-docbook/trunk/README?view=log here]) and '''doc-docbook/Makefile.targets''' (WebSVN version [http://inkscape.svn.sourceforge.net/viewvc/inkscape/doc-docbook/trunk/Makefile.targets?view=log here]). | |||
== Keyboard and mouse translation == | |||
* TBD | * TBD | ||
= User Manual = | == User Manual == | ||
* See also [[Embedded Help]] | * See also [[Embedded Help]] | ||
* First download the user manual xml document from [http://svn.sourceforge.net/viewcvs.cgi/inkscape/user_manual/trunk/xml/ SVN] | * First download the user manual xml document from [http://inkscape.svn.sourceforge.net/viewcvs.cgi/inkscape/user_manual/trunk/xml/ SVN] | ||
* edit the trunk/xml/inkscapeUTF.xml file. All languages are inside. | * edit the trunk/xml/inkscapeUTF.xml file. All languages are inside. | ||
* Just read the file, choose the language reference you want to use (en, fr...) and translate by duplicating the node and changing lang attribute to yours. | * Just read the file, choose the language reference you want to use (en, fr...) and translate by duplicating the node and changing lang attribute to yours. | ||
| Line 29: | Line 56: | ||
* submit your work as a patch in the patch tracker and warn Cédric Gemy (cedric at le-radar.com) by email. | * submit your work as a patch in the patch tracker and warn Cédric Gemy (cedric at le-radar.com) by email. | ||
= | == Manual pages (man)== | ||
* first download inkscape.pod from [http://svn.sourceforge.net/viewcvs.cgi/inkscape/inkscape/trunk/inkscape.pod?view=log SVN] | * first download inkscape.pod from [http://inkscape.svn.sourceforge.net/viewcvs.cgi/inkscape/inkscape/trunk/inkscape.pod?view=log SVN] | ||
* rename it to inkscape.xx.pod, where xx is the code for your language | * rename it to inkscape.xx.pod, where xx is the code for your language | ||
* open inkscape.xx.pod in your favourite text editor (pay attention to encoding which must be UTF8), and directly translate in the file. | * open inkscape.xx.pod in your favourite text editor (pay attention to encoding which must be UTF8), and directly translate in the file. | ||
| Line 37: | Line 64: | ||
* finally, submit your work in the patch tracker and drop a mail to the inkscape devel mailing list. | * finally, submit your work in the patch tracker and drop a mail to the inkscape devel mailing list. | ||
= Translation information = | == Translation information == | ||
Go Back to the main [http://wiki.inkscape.org/wiki/index.php/Translation_information Translation information] page. | Go Back to the main [http://wiki.inkscape.org/wiki/index.php/Translation_information Translation information] page. | ||
[[Category: Developer Discussion]] | [[Category: Developer Discussion]] | ||
Revision as of 19:27, 11 October 2009
Go Back to the main Translation information page.
Tutorial Translation
Inkscape's tutorial sources are in Docbook XML format, with illustrations in SVG.
The translations of the tutorials however are in the well-know PO format. If you want to help, download them here:
http://inkscape.svn.sourceforge.net/viewvc/inkscape/doc-docbook/trunk/
- Each tutorial is in its own subdirectory. You need the
<LANG>.pofile, for examplebasic/fr.po. Please coordinate with the previous translator listed in that file! - If there is none of these files, get the
<tutorial>.potfile, rename it to<LANG>.poand start translating.
Once you are satisfied with what you have done, submit it to the Launchpad bug tracker. Open a new bug with name translation to <your language>, upload the po-file there as attachment. You need to create an account on ubuntu launchpad if you have no account there, yet.
Thanks!
When adding a new tutorial SVG to the SVN (to the tutorial directory), it's recommended to also perform the following steps:
- Add the filename of the tutorial SVG (and any additional files it needs, like PNG images referenced from the SVG) to share/tutorials/Makefile.am in the main inkscape trunk.
- If the SVG refers to a PNG, then that PNG should exist in the SVG's directory -- make sure to also commit that PNG.
- Modify the translation of the tutorial filename in the main PO file so as to make Inkscape display the localized tutorial instead of the default (English) one. An example: if the
"tutorial-basic.svg"string is translated the following way in po/fr.po
msgid "tutorial-basic.svg"msgstr "tutorial-basic.fr.svg"
- then whenever the locale is French, Inkscape will display the French (and not the default English) basic tutorial for users.
- Update the translation status in the wiki.
You may also check the tutorials with the check_for_tutorial_problems.sh script. See the comments inside the script for more information.
Verification
To create up-to-date tutorials (the tutorial-*.svg files), you'll need to build them from the tutorial PO files. Here's how to do it:
- Install Saxon 6.5.x (Saxon is a tool that converts XML to SVG using XSLT, see saxon.sf.net) if it's not already installed. You can install it with your package manager or by downloading the appropriate file from the Saxon homepage and unzipping it into a suitable directory. You need to install version 6.5.x -- the build process doesn't work with newer versions. E.g. under openSUSE, install saxon-6.5.5 or a similarly named package -- NOT saxon8 or similar. The build scripts need to find saxon.jar in your Java classpath -- you may want to check your classpath in case of a Java problem.
- Install Java SDK (JRE is not enough) if it's not already installed. Under openSUSE, the package name should be java-1_6_0-sun-devel or something similar. You can check your installation with
type java
from the command line -- check that java actually points to the SDK's java executable that you installed. - Update your local copy of the docbook trunk and the main inkscape trunk from SVN.
cd doc-docbook/javaclasses/org/inkscape/xslt; javac files.java
(doc-docbook/ being the root of your local copy of the docbook trunk) (this rebuilds files.class, which is a Java class file)cd doc-docbook/
(doc-docbook/ being the root of your local copy of the docbook trunk)make svg
(this creates all tutorial SVGs for all languages -- can take long)- Check the newly created tutorial SVGs (which you'll find in their specific tutorial directories: advanced/, basic/, ...) for overlapping text (often caused by font settings) and other problems. It's recommended to perform the check under a different operating system. If the SVGs have overlapping text, check the default fonts on your computer.
- If you want to commit the newly created tutorial SVGs, then copy the new tutorial-*.svg files to the share/tutorials/ directory of your local copy of the main inkscape trunk and commit them to the main inkscape trunk.
For more information, see doc-docbook/README (WebSVN version here) and doc-docbook/Makefile.targets (WebSVN version here).
Keyboard and mouse translation
- TBD
User Manual
- See also Embedded Help
- First download the user manual xml document from SVN
- edit the trunk/xml/inkscapeUTF.xml file. All languages are inside.
- Just read the file, choose the language reference you want to use (en, fr...) and translate by duplicating the node and changing lang attribute to yours.
- when finishing editing, if necessary edit the Makefile and add your language to the Makefile. In every case test your file with some tools (xmllint...) or just type again "make your_language" : syntax errors will be displayed : please correct them.
- submit your work as a patch in the patch tracker and warn Cédric Gemy (cedric at le-radar.com) by email.
Manual pages (man)
- first download inkscape.pod from SVN
- rename it to inkscape.xx.pod, where xx is the code for your language
- open inkscape.xx.pod in your favourite text editor (pay attention to encoding which must be UTF8), and directly translate in the file.
- you can take a look at a first example of translation with inkscape.fr.pod
- finally, submit your work in the patch tracker and drop a mail to the inkscape devel mailing list.
Translation information
Go Back to the main Translation information page.