source: jclic/trunk/fuentes/i18n/README @ 3466

Last change on this file since 3466 was 3466, checked in by Juanma, 4 years ago

Updated to 3.2.1

File size: 2.9 KB
Line 
1JClic internationalization README
2
3INTRODUCTION
4
5JClic, as many Java apps, uses the Java Internationalization API [1] to display
6text expressions in different languages. This API uses files with extension
7".properties" to store the messages.
8
9Due to its modular design, JClic makes use of 10 different ".properties" files,
10located in deep path levels on the "src" directory, like:
11"src/core/edu/xtec/resources/messages/JClicMessages.properties". This makes
12complicated to start a new translation and maintain it in successive releases.
13
14Launchpad Translations [2] (formerly known as Rosetta) is a web-base translation
15system integrated in the Launchpad free software development platform. It's very
16useful and easy to use for translators, because tracks all changes and allows to
17reuse expressions already translated in other projects.
18
19Launchpad Translations are based on the GNU gettext system [3]. This system makes use
20of files with extension ".po" to store messages. ".po" files have different format
21and coding conventions than ".properties".
22
23The utilities in this section allow to convert the original ".properties" files
24located in the src directory of JClic into ".po" files, in order to make possible the
25use of Lanunchpad Translations, and implement also the inverse path converting the
26".po" files returned by Launchpad to ".properties".
27
28SYSTEM REQUIREMENTS
29
30- Apache Ant 1.6 or later
31- tar command available
32- po2prop and prop2po utilities from Translate toolkit
33  (http://translate.sourceforge.net/wiki/toolkit/index)
34
35PREPARING THE APACHE ANT EXTENSIONS
36
37Start compiling the Ant extensions located in i18n/customAntTasks. Go to this directory
38and call "ant" without parameters. This will generate a file named "transToolsAntTasks.jar"
39
40Register this file as an Ant extension. See Apache Ant documentation for more information
41about how to achieve:
42http://ant.apache.org/manual/using.html#external-tasks
43
44PREPARING .po FILES FROM .properties
45
46Go to i18n/toLaunchpad and call "ant". This will generate the "po" directory with subdirectories
47for all JClic modules. The .po and.pot files will be placed into this directories.
48
49RECOVERING .po FILES FROM LAUNCHPAD
50
51Request the JClic translations in Launchpad. It will give you a file called "launchpad-export.tar,gz".
52Place this file into the directory i18n/fromLaunchpad, go to this directory and launch "ant". This
53will extract the returned ".po" files and, if they are different from the existing ones, they will be
54converted to .properties and copyied into the "src" directory.
55
56You can also place individual .po files into i18n/fromLaunchpad/po and call "ant" to complete the
57conversion process. Note that .po files returned from Launchpad can have different names than the
58expected by JClic. For example, jclicmessages-ca.po must be translated to JClicMessages_ca.po.
59
60
61
62
63
64
65
66
67
681: http://java.sun.com/javase/technologies/core/basic/intl/
692: https://launchpad.net/rosetta
703: http://www.gnu.org/software/gettext/
Note: See TracBrowser for help on using the repository browser.