Difference between revisions of "Translating ccPublisher"
Line 2: | Line 2: | ||
[[Category:Developer]] | [[Category:Developer]] | ||
− | |||
ccPublisher 2.2 (currently under development) will focus on providing internationalization (i18n) support. This document is a work in progress that describes the translation process which will be used once ccPublisher 2.2 release candidates are available. | ccPublisher 2.2 (currently under development) will focus on providing internationalization (i18n) support. This document is a work in progress that describes the translation process which will be used once ccPublisher 2.2 release candidates are available. | ||
Translations for ccPublisher are stored in gettext message catalogs. Message catalogs are text files which associate translated strings with identifiers used by the application. Each string to be translated is referred to as a "message". | Translations for ccPublisher are stored in gettext message catalogs. Message catalogs are text files which associate translated strings with identifiers used by the application. Each string to be translated is referred to as a "message". | ||
+ | |||
+ | == Getting Help == | ||
+ | |||
+ | The [http://lists.berlios.de/mailman/listinfo/cctools-i18n cctools-i18n] mailing list at Berlios.de is used for managing translations for ccPublisher. If you are translating ccPublisher into a new language, you are encouraged to join this list. The addition of new messages to be translated will be announced there, and you may ask questions on the list regarding internationalization. The availability of new message catalogs will also be announced there. | ||
== Creating A Translation == | == Creating A Translation == | ||
− | When translating ccPublisher there are two files which must be copied and editted for the core application. [[Extending ccPublisher|Extensions]] may have their own message catalogs which need translating (see [[Translating Extensions]] for details on internationalizing ccPublisher extensions). The translation resources are located in the <code>resources/locale</code> subdirectory for a [[Developing ccPublisher 2|development sandbox]]. Use the following instructions to create a new translation for ccPublisher; these instructions are for translating ccPublisher to the fictional "ya" locale and assume a Linux development environment | + | When translating ccPublisher there are two files which must be copied and editted for the core application. [[Extending ccPublisher|Extensions]] may have their own message catalogs which need translating (see [[Translating Extensions]] for details on internationalizing ccPublisher extensions). The translation resources are located in the <code>resources/locale</code> subdirectory for a [[Developing ccPublisher 2|development sandbox]]. Use the following instructions to create a new translation for ccPublisher; these instructions are for translating ccPublisher to the fictional "ya" locale and assume a Linux development environment. |
* Create a locale subdirectory for your new translation | * Create a locale subdirectory for your new translation | ||
Line 26: | Line 29: | ||
msgstr "" | msgstr "" | ||
... | ... | ||
− | |||
− | |||
− | |||
− | |||
* Run ccPublisher with the <code>--locale</code> parameter; alternately if working on your default locale, omit the parameter and ccPublisher will use the operating system's default locale information. | * Run ccPublisher with the <code>--locale</code> parameter; alternately if working on your default locale, omit the parameter and ccPublisher will use the operating system's default locale information. | ||
Change to the sandbox root directory | Change to the sandbox root directory | ||
$ cd ../../.. | $ cd ../../.. | ||
$ python ccp.py --locale ya | $ python ccp.py --locale ya | ||
+ | |||
+ | ccPublisher will recompile the .po files into binary message catalogs (.mo files) when it runs if the .po files are newer or the .mo files do not exist. This feature exists to aid translators. | ||
+ | |||
+ | === Translating under Windows === | ||
+ | |||
+ | ''coming soon...'' | ||
+ | |||
+ | === Translating under Mac OS X === | ||
+ | |||
+ | ''coming soon...'' | ||
== Submitting a Translation == | == Submitting a Translation == | ||
− | Once you have completed or updated a translation and tested it, you can submit it to the ccPublisher developers using the Roundup bug tracking system. | + | Once you have completed or updated a translation and tested it, you can submit it to the ccPublisher developers using the Roundup bug tracking system. [http://roundup.creativecommons.org/ccpublisher/issue?@template=item&topic=i18n&priority=feature&title=New+Translation Click here] to create a new issue with the correct default values set. Add the locale information for your new translation to the title and attach the .po files you created (either individually or in a zip/tar file). |
− | + | We encourage people submitting bugs and feature requests via Roundup to create accounts so they can easily monitor issues they create. | |
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
== Supported Languages == | == Supported Languages == |
Revision as of 15:14, 5 June 2006
ccPublisher 2.2 (currently under development) will focus on providing internationalization (i18n) support. This document is a work in progress that describes the translation process which will be used once ccPublisher 2.2 release candidates are available.
Translations for ccPublisher are stored in gettext message catalogs. Message catalogs are text files which associate translated strings with identifiers used by the application. Each string to be translated is referred to as a "message".
Contents
Getting Help
The cctools-i18n mailing list at Berlios.de is used for managing translations for ccPublisher. If you are translating ccPublisher into a new language, you are encouraged to join this list. The addition of new messages to be translated will be announced there, and you may ask questions on the list regarding internationalization. The availability of new message catalogs will also be announced there.
Creating A Translation
When translating ccPublisher there are two files which must be copied and editted for the core application. Extensions may have their own message catalogs which need translating (see Translating Extensions for details on internationalizing ccPublisher extensions). The translation resources are located in the resources/locale
subdirectory for a development sandbox. Use the following instructions to create a new translation for ccPublisher; these instructions are for translating ccPublisher to the fictional "ya" locale and assume a Linux development environment.
- Create a locale subdirectory for your new translation
$ cd resources/locale $ mkdir ya $ mkdir ya/LC_MESSAGES
- Copy the template files into the new directory
$ cp ccpublisher.pot ya/ccpublisher.po $ cp p6.pot ya/p6.pot
- Edit the new files with the translated content. Two areas need editted: the header information and the messages.
- The header information should be updated with the translator's contact information, email address and the character set used. The character set should usually be
utf-8
. - Each message is defined by two lines; the translated content goes between the quotes on the
msgstr
line. Themsgid
line must not be changed.
- The header information should be updated with the translator's contact information, email address and the character set used. The character set should usually be
... msgid "OK" msgstr "" ...
- Run ccPublisher with the
--locale
parameter; alternately if working on your default locale, omit the parameter and ccPublisher will use the operating system's default locale information.
Change to the sandbox root directory $ cd ../../.. $ python ccp.py --locale ya
ccPublisher will recompile the .po files into binary message catalogs (.mo files) when it runs if the .po files are newer or the .mo files do not exist. This feature exists to aid translators.
Translating under Windows
coming soon...
Translating under Mac OS X
coming soon...
Submitting a Translation
Once you have completed or updated a translation and tested it, you can submit it to the ccPublisher developers using the Roundup bug tracking system. Click here to create a new issue with the correct default values set. Add the locale information for your new translation to the title and attach the .po files you created (either individually or in a zip/tar file).
We encourage people submitting bugs and feature requests via Roundup to create accounts so they can easily monitor issues they create.
Supported Languages
ccPublisher includes support for the following languages:
- English
The following languages will be included in the next release:
(none)