i18n
We need internationalization support.
http://docs.python.org/2/library/gettext.html#internationalizing-your-programs-and-modules
We should start by marking all our message strings using the _() function. Afterwards we can run pygettext on it to create *.pot files, which in turn can be easily translated.
i can help with the spanish translation
We're currently testing Python internationalization in the i18n branch, but it only deals with messages in cherrymusicserver/__init__.py so far.
In that branch, I created a :es: language file in res/i18n/po/es.po, which contains the English messages and their translations (currently empty). If you want, you can give it a try, maybe using a tool like poedit for convenience.
We'll eventually cover all messages and merge into devel.
Thats great! Anyway i prefer any text editor :P
Also, I think it would be more convenient to comment the environment of the messages to know exactly what it means.
The i18n branch now has a translation generation script. It only works on linux right now and requires python3.
We can now easily add translations (by creating a new subfolder for a specific translation which cantains an LC_MESSAGES folder) and update the needed translations from the source code automatically.
the script is in res/i18n/update_translations.py
I've also merged the latest devel into the i18n branch. we might as well merge it into devel already.
todo:
- [ ] elegant solution for translating the client side (see cherrymusicserver/i18n_client.py)
- [ ] mark all translatable strings in the source code
- [ ] invite people to translate CM into their native language
- [ ] set the default client language to that of the server, but let users choose other translations