mozdev.org

freetranslate

resources:
 

freetranslate extension localisation

Thanks mainly to the contributions from Luana Di Muzio for the standard xpi locale structure and Italian translations and JB Marcon for the French translations the freetranslate.xpi extension now has even better locale support.

Hopefully in the future we should have many more languages supported, so if you think you can help with the translations here's the basic process.

 

Locale structuring in an XPI:

Inside the freetranslate.xpi (rename freetranslate.zip and open) there is the following folder structure:

For each language there is a locale folder (en-US, fr-FR, it-IT) in the locale/freetranslate folder. Depending upon which language the browser has been set to, Firefox will replace the placeholders in the extension with values from the respective locale folder.

 

As you can see there are 3 files in each of the locale folders,

1. contents.rdf / the blue highlighted terms need to be replaced with their 4 character locale equivalents. (e.g. en-US -> fr-FR)

2. freetranslate.dtd / this file holds the placeholders (entities) which are implemented at runtime. The orange highlighted terms need to be replaced with their localised equivalent.

 

3. freetranslate.properties / this file holds the initial description string for the extension as found in the extension dialog box. The green highlighted text need to be replaced with its localised equivalent.

 

And that's about it. Just place all 3 localised versions of the files in a language locale folder, zip them up and send them to :

If you want to check which languages freetranslate.xpi has already been translated into you can find it here on the main page.

 

Useful links:

Great tutorial illustrating how to localise a Firefox extension : link

An excellent thread regarding XPI localisation : link

Here's a tutorial about how to localise the initial description : link

A locale switching extension from Benjamin Smedberg : link

And the language packs for the 1.0.7 release of Firefox: link

 

 

 

 

 

 

The freetranslate project can be contacted through the mailing list or the member list.
Copyright © 2000-2017. All rights reserved. Terms of Use & Privacy Policy.