Table of Contents
- Contributing to translations
- Step 1: Join the Crowdin project
- Step 2: Activate your language
- Step 3: Translate strings
- Step 4: Proofread translations
- Managing translations
Contributing to translations
The Flowee Pay graphical user interfaces are translated on Crowdin:
Step 1: Join the Crowdin project
To contribute to translations, you must create a Crowdin account and join the floweepay project on Crowdin.
Step 2: Activate your language
If you already see your language in the floweepay project on Crowdin, you can skip to step 3.
If not, then a maintainer first needs to turn on your language in the Crowdin project. Ping them on Telegram for instance. See Socials
Step 3: Translate strings
On Crowdin, click on your language and then on a front end like floweepay-mobile.ts to begin translating. Select a source string you want to translate and enter your translation.
At the bottom of the screen, you will find helpful automatic suggestions. Click on a suggestion to use it, and adapt it as needed. The suggestions consist of translation memory and machine translations. Translation memory is previous translations of similar source strings and other translations from other software projects on Crowdin. Machine translations are computer-generated suggestions.
Please take a bit of time to ensure that terminology is consistent throughout your language. You can use the search functionality at the top of the list to find similar usages.
many source translation have a screenshot attached. See the above example where it is just above "FORM ONE OTHER". You can enlarge the screenshot to see where the text actually appears in the application.
Some English texts have a placeholder like "%1". The placeholder "%1" is replaced with specific words of number in the application. So for instance Behind %1 days becomes Behind 10 days in the application, where the number is updated automatically in the application.
In many languages you will have multiple forms for such translation. In English you would have:
- Behind 1 day
- Behind 10 days
You fill in the different translations in the "One" and "Other" tabs, similar if your language use the "Few" / "Many" counting differences.
In the rare case you will find not just "%1" but also "%2". For instance in Behind: %1 weeks, %2 days. Please make sure you keep the intended meaning of each placeholder. So %1 is weeks and in your translation %1 is also an indicator of weeks. The order in which they appear in the translation is not important.
Step 4: Proofread translations
For quality assurance purposes, every proposed translation must be verified by a proofreader before it can be included in the floweepay software. To do so, you first need to obtain the proofreader permission for your language. Contact us if you are a member of the Bitcoin Cash community we can trust and you want to be a proofreader for a particular language.
As a proofreader, you can click the checkmark to mark a translation as verified. Verifying a translation means that it is good enough for inclusion in our software: if unverified, the original American English text will be shown to users instead. It is fine to approve your own translation proposals. If needed, proofreaders can always change previously verified translations at a later moment.
Exporting source strings from Git to Crowdin
As new strings are added to the software, they need to be uploaded to crowdin so translators start working on them.
A developer with the project sources can call the special "make" target
i18n which causes the translation files to be updated. These are placed in the directorie
translations for all front-ends.
On Crowdin, go to Settings, Files, and find the front-end you are updating. For instance
floweepay-desktop.ts click Update, and select the floweepay-desktop.ts from the translations folder that was just generated. Press upload to merge with the previously uploaded one. Translators can now begin translating new/modified source strings.
Importing verified translations from Crowdin into Git
On Crowdin, go to Settings, Translations, and click Build & Download. The build has directories for each language with the front-ends under that. While in git we have one directory per front-end. So you need to copy files and add the language code to the filename.
nl/floweepay-desktop.ts is stored in git as
Commit the changes and submit them as a Merge Request.
Since Export only approved translations is enabled in the Crowdin project settings, any unverified translations won't be included in your download!
Registering languages in FloweePay
To start a new language for a certain front-end, several steps are needed.
Update the CMakeLists.txt and in the lines under
set (TS_FILESadd your wanted translations filenames. The language code are explained on Crowdin, language codes.
You will need to edit the i18n manifest file for your front-end in a simple text editor. For instance
translations/desktop-i18n.qrcand add a new entry. Below is an example of the Dutch language entry.
<qresource prefix="/i18n"> <file>floweepay-desktop_nl.qm</file> <file>floweepay-common_nl.qm</file> ... </qresource>
Note that the language translation file must end in .qm (the compiled extension), and not .ts as they are stored in git.