Repository navigation
Conversation
|
I have been working on a zh-TW localization for Omarchy, so I tested this against the Traditional Chinese locales. One issue is worth fixing before this lands, and one change looks broader in scope than the PR title suggests.
readonly property bool chineseUi: uiLanguage.toLowerCase().indexOf("zh") === 0
Keying on the script rather than on the function isSimplified(v) {
var s = String(v || "").toLowerCase().split(":")[0].split(".")[0].replace(/-/g, "_")
return s === "zh" || /^zh_(cn|sg|hans)\b/.test(s) || /^zh_hans_/.test(s)
}Traditional users then see English, which is the correct outcome until a Note also that
After this change a French or German desktop gets localized month and weekday names in the calendar while the rest of the shell stays English — a mixed-language panel for users this PR does not otherwise touch. That may well be desirable — and in fact #10955 by @sbelcl proposes exactly this change on its own, covering On the parts that are right: translating at the last hop before display is the correct direction. For what it's worth, I also checked that this does not collide with #12338 (which makes the menu search line a real text input, for CJK input method support): |
|
Appreciate the zh-CN pass. There's a broader i18n cluster (#8765 / #10083 / #15151 / #11010 / #15117) — product should pick one framework direction before landing partial hard-coded maps. Also +1 to @linyiru: |
- Add ZhCN.isSimplified() keyed on script/region (zh, zh_CN, zh_SG, zh_Hans) so zh_TW/zh_HK/zh_MO/zh_Hant no longer get Simplified Chinese. - Revert clock Panel.qml labelLocale change; leave it to omacom#10955. - Update docs/chinese-ui.md to document the Simplified-only behavior.
|
Thank you for this. What it does is now on Simplified Chinese ( This was checked against |
Summary
This pull request adds initial Simplified Chinese localization support for the Omarchy shell.
LANGorLANGUAGEstarts withzh.OMARCHY_UI_LANGUAGE=zh-CNorOMARCHY_UI_LANGUAGE=en.Backward compatibility
The default English UI remains unchanged for non-Chinese locales.
Verification
bash test/shell.d/menu-test.shgit diff --check