Skip to content

Add Simplified Chinese (zh-Hans) - #571

Merged
125hz merged 1 commit into
willfaust:mainfrom
symi-daguo:zh-Hans
Nov 5, 2026
Merged

125hz merged 1 commit into
willfaust:mainfrom
symi-daguo:zh-Hans

Conversation

@symi-daguo

Copy link
Copy Markdown

Adds Simplified Chinese to the String Catalog. Nothing else changes for the five languages that are already there.

What it does

  • Localizable.xcstrings: zh-Hans for all 848 keys.
  • project.pbxproj: zh-Hans in knownRegions.

Two gaps I hit while translating (both leave English on screen in every language, not just Chinese):

  1. The catalog had drifted from the source. 92 strings that reach the UI — the EA/Epic/GOG/itch.io sign-in pages, achievements, touch-control settings, the FPS graph, external drives — were never extracted, so they were never in the catalog at all. Added with a zh-Hans value only; other languages fall back to English exactly as they do today.
  2. All and Other are looked up at runtime through L(), so extraction never saw them either. Added as manual entries.

I also changed two call sites that built a String ternary (Text(search.isEmpty ? "..." : L("..."))), which Text(String) renders verbatim, so the empty-library note stayed English. They now go through L() like the rest of the library. That is the only Swift change (2 lines).

Checked

  • xcstringstool compile passes with no warnings, positional specifiers (%@, %lld) preserved in every translation.
  • Debug build of v0.2.0, installed on an iPhone (iOS 27.2): library, filter chips and the empty-library note render in Chinese; the built bundle carries 848 zh-Hans entries.
  • Untouched: de, es, ko, pt-BR, ru.

Brand names (Steam, GOG, itch.io, Epic, EA, Wine, DXMT, Visual C++, …) and paths (C:\…) are left as-is, and quotes around UI labels follow Chinese typography (「」).

Happy to split the two catalog-gap items into their own PR, or to drop the Swift change, if you would rather review them separately.

Resources:
- Localizable.xcstrings: zh-Hans for all 848 strings, and zh-Hans in
  project.pbxproj's knownRegions. Other languages are untouched.

Two gaps found while doing it, both of which left English on screen in
every language:

- The catalog had drifted from the source: 92 strings that reach the UI
  (EA/Epic/GOG/itch.io sign-in pages, achievements, touch-control
  settings, the FPS graph, external drives) had never been extracted.
  They are added with a zh-Hans value only.
- "All" and "Other" are looked up at runtime through L(), so extraction
  never saw them either; added as manual entries.
- Two call sites built a String ternary, which Text(String) renders
  verbatim, so the empty-library note stayed English; they now go
  through L() like the rest of the library.

Checked with xcstringstool compile (no warnings) and on an iPhone running
iOS 27.2: library, filter chips and the empty-library note render in
Chinese, and the built bundle carries 848 zh-Hans entries.

Signed-off-by: symi-daguo <symi-daguo@gmail.com>
@125hz
125hz merged commit f2fbc1a into willfaust:main Nov 5, 2026
125hz pushed a commit that referenced this pull request Nov 5, 2026
Adds Simplified Chinese to the String Catalog. Nothing else changes for the five languages that are already there.
125hz added a commit that referenced this pull request Nov 5, 2026
…he translations check knows the sixth language (#571 follow-up)

The 94 keys that existed only with a Chinese value are dropped (they were never looked up: the texts reach the screen through plain String parameters, and check-translations requires every key in every language); 31 Chinese values get positional placeholders (%1$@, %1$lld / %2$lld) matching the English; two trailing spaces are restored. tests/host/check-translations.py lists zh-Hans with the other five languages and checks it in knownRegions.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
icey9527 added a commit to icey9527/Madeira-15.6 that referenced this pull request Nov 6, 2026
Upstream wave 7: Simplified Chinese for every catalog key (willfaust#571), a Japanese
locale per game (willfaust#567), thread-context and JIT-pool fixes (willfaust#556), Steam depot
overlap scoped per install folder (willfaust#576), achievements, DXT9 luminance
render targets, and the index-range DXMT patch that now compiles against a
newer dxmt.

Kept the fork: the Chinese locale work now sits on upstream's full
translation, the Japanese prefix and our GBK path both run, both font
folders ship, and the vendored dxmt gained the two device methods the
re-enabled patch needs.

Co-Authored-By: Claude Code <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants