Translations

Existing Translations
There is no coordinated effort to translate StatusNet at this point in time. 14:26, 2 October 2013 (UTC)

How to Translate StatusNet
As with many other Open Source projects, StatusNet uses gettext for translations. All through the code the strings are inside the gettext translation function eg. `_('Register')`. This allows StatusNet to be translated into any language without the code needing to be modified.

Internationalisation notes for developers
See i18n guidelines for some common pitfalls, and some ways you can make things easier on your translators!

Translating/Overriding Help documentation
Copy the /doc-src/ directory to /statusnet/local/ those docs will allways be shown first. Add different language files with a language code suffix, so about.zh for Chinese, about.fr for French and about for default (English)

Open issues

 * 1661 - registration problem
 * 534 - translatable texts should be full phrases including punctuation
 * keep this in mind when poking at code -- I18n guidelines
 * 481 - Galician translation

Alternate editing interfaces
Recommendations to investigate so far: * http://www.transifex.net/
 * http://translatewiki.net
 * Interface & performance work desirable, but infrastructure is there and they're happy to work with us.
 * Good git integration, but on-web editor isn't ready yet. Dev version technically works for large files like ours, but isn't really usable the way it pages all strings into an unsearchable list.
 * http://launchpad.net/
 * Pootle
 * Just released version 2.0, VCS integration, online web editor, alternative source languages, RSS feeds, ... Live demo at http://pootle.locamotion.org/

Gettext problems

 * gettext module not always available - fixed in 0.8.2
 * resolved by using php-gettext as fallback
 * setlocale+gettext fail if the system doesn't have the locale installed - fixed in 0.9.x
 * Resolved this by setting locale to existing en_US before user locale.
 * inconsistencies with locale naming (es vs fr_FR) - fixed in 0.9.x
 * aggravates the above
 * setlocale+gettext may have unpredictable results on multithreaded servers
 * locale settings are process-wide so may affect multiple threads... this is most likely on Windows, since Unix web servers usually fork multi-process
 * setlocale doesn't support UTF-8 locales on Windows? (untested)

Using php-gettext should work for any locale regardless of whether it's available on the system, but if PHP's gettext module is present we have no way to override calls like '_("blah")'. We'd have to change all calls to _gettext or __ or something. Annoying for code maintenance, but possible.

So far that's not a high priority, since the most common problems seem to have been resolved. --brion 22:37, 21 October 2009 (UTC)