Add Simplified Chinese interface localization - #1716
Conversation
|
@jianchuanqi Hi there! Thank you very much for your efforts here!! The PR you made is an interesting addition to the AB. Here some of my thoughts:
Happy to talk more about this to find the best solution! |
|
Thanks, this is very helpful. My intention is to support AB3, so I agree that The PoC will cover only a few representative cases: a static action or label, a formatted dialog message, a table/model header, and a translated display label separated from its stable internal ID. Scientific and database content will remain outside the translation layer. I can act as the initial maintainer for the Simplified Chinese translation. English will remain canonical, and missing or unfinished translations will fall back to English, so normal development and releases will not be blocked. CI will fail only on structural problems such as invalid catalogs or placeholder mismatches, while translation coverage will be informational. I plan to use the native Qt TS/QM translation workflow unless you would prefer another direction. I will link the new draft PoC here once it is ready. |
Summary
This PR adds application-wide interface localization and a complete Simplified
Chinese UI option to Activity Browser.
built-in dialogs.
Project > Settings...; language changes take effect after restart.
messages, and embedded web/start-screen content.
introducing stable semantic IDs where needed.
Why
Activity Browser currently exposes its interface only in English. Adding an
internationalization layer makes the application usable in Simplified Chinese
and establishes a catalog structure that can support additional interface
languages later.
The language setting affects only interface text. Scientific database content,
activity names, impact assessment methods, units, and exported source data are
not translated or modified.
Documentation
in
activity_browser/docs/wiki/Settings.md.Validation
python -m pytest -qon the 13 newly added localization test modules:97 passed.
python -m pytest -q tests/actions/test_activity_actions.py tests/actions/test_various_actions.py tests/legacy/test_settings.py:27 passed (12 existing pytest-qt deprecation warnings).
git diff --check upstream/main...HEAD: passed.The repository's full GitHub Actions matrix should provide final validation on
Python 3.10 and 3.11 across Linux, Windows, and macOS.
Review note
Although this is one cohesive feature, it necessarily touches many UI call
sites because the existing English strings were embedded directly throughout
the application. The PR is opened as a draft so maintainers can advise whether
they prefer the framework, catalog, and call-site migration to be reviewed in
separate stages.
Checklist
activity_browser/docs/wiki/Settings.md.No existing related issue was found, so no closing keyword is included.
If you have write access (otherwise a maintainer will do this for you):
featureoruilabel.