Author Topic: Add new language to FirefoxOS  (Read 2858 times)

Offline coyan

  • Full Member
  • ***
  • Thank You
  • -Given: 0
  • -Receive: 1
  • Posts: 117
  • Karma: 5
    • View Profile
    • CoyáN.es
Add new language to FirefoxOS
« on: January 20, 2014, 07:21:15 AM »
I want to help in a new localization, therefor, what are the steps to do? I think it's a good idea to explain here a detailed process to help in new translations.

Can someone help me to define the entire process? I'll update this message with the corrections. Thanks in advance.


Localization
Short instructions to create a new language in FirefoxOS:

Keep in mind that https://hg.mozilla.org/gaia-l10n is the most recent strings, you need to maintain for all diferent versions (remember that you can merge the most recent to master to not translate a string twice).
For example https://hg.mozilla.org/releases/gaia-l10n/v1_2 and https://hg.mozilla.org/releases/gaia-l10n/v1_3
An useful tool is http://transvision.mozfr.org/gaia/ where you can compare the strings.


Keyboard
If your new language needs a keyboard (for example in the country the main currency is the € instead of the $ or you have a special letter like the spanish "ñ").

Go to https://github.com/mozilla-b2g/gaia/tree/master/keyboard/layouts and add your language's new layout.

Example: if you see the "keys" section on https://github.com/mozilla-b2g/gaia/blob/master/keyboard/layouts/es.js the keyboard is similar to QWERTY's English but with the "ñ" beside the "l" and the symbols are in other order.

Useful links
Example of a Bug asking to add a new language => https://bugzilla.mozilla.org/show_bug.cgi?id=946057
How the Mozilla L10n works? => https://wiki.mozilla.org/L10n:Home_Page
Localization tool for Mozilla projects => https://localize.mozilla.org/

Phonification :)
When all is finished here you can find the instructions to build a localized image for testing: https://github.com/mozilla-b2g/gaia/tree/master/locales Change /gaia/tree/master for the branch that you are testing, for example if your translation is based in 1.3 version you need: https://github.com/mozilla-b2g/gaia/tree/v1.3/locales

If your translation is finished and all works as expected you can ask in Geeksphone forum to add the language to the images on http://downloads.geeksphone.com/

Offline scootergrisen

  • Jr. Member
  • **
  • Thank You
  • -Given: 0
  • -Receive: 3
  • Posts: 67
  • Karma: 3
    • View Profile
    • Netkoder.dk
Re:Add new language to FirefoxOS
« Reply #1 on: January 24, 2014, 07:48:44 PM »
Good idea to make a guide about it. ;D
I had a hard time figuring out what to do.

About keyboard the language also need to be in this file i think :
https://github.com/mozilla-b2g/gaia/blob/master/locales/languages_all.json
And maybe this one to, it dont know exactly why there are two :
https://github.com/mozilla-b2g/gaia/blob/master/locales/languages_dev.json

I also chatted on IRC with the chatzilla addon : https://addons.mozilla.org/en-US/firefox/addon/chatzilla/
Using network moznet and joining channels #b2g and #gaia.
That helped alot when not knowing what to do and getting things explained.

Offline Kyle6

  • Newbie
  • *
  • Thank You
  • -Given: 0
  • -Receive: 0
  • Posts: 1
  • Karma: 0
    • View Profile
Re: Add new language to FirefoxOS
« Reply #2 on: October 09, 2016, 11:51:19 PM »
Thanks for your helpful post Coyan, I've added it to my bookmarks list.