SlicerLanguagePacks: New extension for translating user interface of Slicer to various languages

We added a new extension that allows translators to see the translation results immediately. It can download and install nightly translations with a single click. It can also install latest translations that are downloaded from Crowdin website.

See setup and usage instructions on the extension’s website.

Currently, it requires downloading and installing the Qt toolkit, which is not very convenient (it can take 10-15 minutes). In the near future we will remove this requirement - see details here.

Any feedback and suggestions are welcome.


A few updates about recent developments.

1. Switch to Weblate

After lengthy discussions and testing, we switched the online translation file editing platform from Crowdin to Weblate.

Crowdin was simple to set up but even after a few weeks we ran into problems due to limitations in feature set and configurability - which were not issues on Weblate. Crowdin most important limitations for use included:

  • Lack of attribution: While Crowdin internally keeps track of who added a translation, that information is not available in our github repository. Therefore, contributions of translators cannot be properly publicly acknoledged. In contrast, Weblate properly sets contributor information in each commit in our github repository, see example.
  • Lack of open access: Crowdin website required registration, even for just viewing the site content. In contrast, Slicer project on Weblate can be accessed publicly, without user registration.
  • Limited bulk data download: Crowdin required manual download of translation files and limited multi-language downloads to managers. In contrast, Weblate allows anyone downloading one or more language packs using simple web requests (this allows single-click language file update in LanguagePacks extension).
  • Insufficient access control granularity. Crowdin only has 3 fixed roles (translator, proofreader, manager), and we could not configure the site to fulfill our requirements (for example glossary was only editable by managers, while we wanted to allow the community to build the glossary). In contrast, Weblate has fine-grained access control, with customizable roles and permissions.
  • Limitations in size and versioning of translations: Crowdin’s free service only supports 60k words and 1 branch for translation. This would be most likely sufficient for translating Slicer core, but not for translating documentation; and would have required workarounds for managing translations of multiple Slicer versions. In contrast, Weblate supports 10k strings and unlimited number of branches. There are examples of Weblate being used for translating documentation hosted on read-the-docs.
  • Crowdin is closed-source, users do not have the option for self-hosting (maybe except some very expensive enterprise contracts). In contrast, Weblate is open-source and can be self-hosted for free.

Currently, we still accept translations from Crowdin, but we will close that project in about a week.

From now on, please add/edit Slicer translations on Weblate.

Instructions for creating and testing translations are provided in the LanguagePacks extension documentation. If you have any questions, please post a new topic (use the i18n tag to indicate that your question is related to internationalization).

2. New “Find text” tool for finding text displayed in Slicer on Weblate website

A convenient tool is added to LanguagePacks extension that allows quickly grabbing text from the Slicer user interface and open look it up on the Weblate website:

See detailed instructions here.

3. Next steps

Currently, all text that are marked as translatable in C++ source code and in .ui files are translatable. We are working on making all strings translatable (CLI modules, Python scripts, various dynamically generated strings).

You can track the progress of our work here:

1 Like

2 posts were split to a new topic: HTML code gets corrupted in language translation files

We are making progress with making more strings translatable. In latest Slicer Preview Releases, all CLI modules are translatable.