![]() |
JSwat ProjectHow to Localize |
Localizing JSwat to other languages should be quite trivial.
Nearly all of the user-readable strings in JSwat are stored in
files called Bundle.properties
in the various code
packages. These files define the strings for the default language,
English. Strings for other languages must be defined in separate
files, using a file naming convention as described in the
documentation for the java.util.ResourceBundle
class.
The steps for localizing JSwat to another language are quite
simple. Start by copying the appropriate
Bundle.properties
file and modifying the strings after
the equals (=) sign on each of the lines in the file. There are
some lines that need not be modified, they are pretty obvious when
you see them. They include the lines that define the menu structure
and toolbar button ordering. Save this new file with a name
appropriate for the target language and country, as described in
the documentation for the java.util.ResourceBundle
class.
After you have created new Bundle.properties
files,
you may launch JSwat on a platform implementing the desired target
language. JSwat should detect the native language and display the
appropriate user-visible strings (actually, it is Java that detects
the language and loads the appropriate properties file).