5.18.2 Different types of resource bundles
There are three different types of resource bundles used by Daisy:
- for the Cocoon part, these are XML files.
- for messages produced by Java code (the repository server), these are " .property" files
- for Javascript, the resource takes the form of a snippet of Javascript code (.js files)
When editing resource bundles, take care of the encoding of the files, as explained below.
5.18.2.1 Encoding of the XML and .js files
We prefer to keep all the XML and .js (javascript) files UTF-8 encoded, for all languages. Therefore, take care to use the correct encoding when opening and saving files in your text editor.
5.18.2.2 Encoding of the .properties files
The ".properties" files should always be ISO-8859-1 encoded. Characters not supported by ISO-8859-1 can be inserted using Java unicode escapes. A Java unicode escape takes the form "\uHHHH" in which the HHHH are hexadecimal digits specifying the unicode character. Usually you don't want to edit this by hand, the unix recode utility can be handy here:
- (if it is an existing file) do:
recode JAVA..UTF-8 somefile.properties
- then open the file in an editor using UTF-8 as encoding
- then convert back:
recode UTF-8..JAVA somefile.properties
Previous