Skip to content

feat(settings): add a Language setting - #82

Merged
Tarquinen merged 1 commit into
devfrom
feat-language-setting
Nov 15, 2026
Merged

Tarquinen merged 1 commit into
devfrom
feat-language-setting

Conversation

@Tarquinen

@Tarquinen Tarquinen commented Nov 15, 2026 •

Copy link
Copy Markdown
Member

Adds a Language row to Settings, after Appearance. It opens a list: System Default (with the system language under it), then every language the app is translated into, each written in its own language. Picking one switches the app right away and stays on the page. It's the same setting as Android's per-app language (Settings › Apps › OpenCode › Language), so the two always match.

As on Android's App language screen, the list has a search field (by the language's own name, its name in the app's language, its English name or its tag) and a Suggested group with the phone's languages.

English is now listed as "English" rather than "English (United States)", here and in Android's screen.

Verified with the full scripts/check.sh, and on the emulator: switched to Deutsch, 日本語, Português (Brasil) and back. The draft, connection and back navigation survive the switch, and changes made in Android's screen show up in the app. Checked in light, dark and large font.

Before After List Search List (dark, German) In Japanese
Settings before Settings with the Language row Language list with Suggested group Searching for German Language list, dark, in German Settings in Japanese

Settings › Preferences gets a Language row, after Appearance. It opens a
list with a search field, System Default (the system language under it),
Suggested (the phone's languages the app supports, in system order) and
All Languages: every language the app is translated into, each named in
itself, with a check on the current one. Search matches a language's own
name, its name in the app's language, its English name or its tag,
ignoring case and accents, and hides System Default and Suggested. Choosing sets the app's language
through Android's per-app language setting (LocaleManager), so it matches
Settings › Apps › OpenCode › Language both ways; System Default clears it.
The languages come from the generated LocaleConfig. Chinese is named by
script (简体中文, 繁體中文).

unqualifiedResLocale is now en instead of en-US, so English is listed as
"English" here and in Android's language screen.

iOS has no language setting; noted as Android-only in docs/parity/settings.md.

Verified: scripts/check.sh (full) on the VM; translate.py all and
translations.py all. On the emulator: switched to Deutsch, 日本語,
Português (Brasil) and back to System Default; stays on the Language page
after the recreation, back returns to Settings and the session with its
composer draft and connection kept; Android's App language screen shows
the same choice, and changing it there updates the row; light, dark and
2.0 font scale; rows are 56 dp radio buttons with checked state. Search
found German by "German", "Deutsch", "de" and "Allemand" (app in French),
"pt-BR" found Português (Brasil), "zzz" showed the empty state, and back
closes the keyboard, then the page. With English and German as system
languages, both show under Suggested in that order.
scripts/check.sh :feature:settings after the search and Suggested changes.
@Tarquinen
Tarquinen force-pushed the feat-language-setting branch from 68b5d82 to 965b134 Compare November 15, 2026 04:20
@Tarquinen
Tarquinen merged commit 10c81d8 into dev Nov 15, 2026
3 checks passed
@Tarquinen Tarquinen mentioned this pull request Nov 15, 2026

This branch was previously deployed

1 inactive deployment
release — 965b1348 Deployed Nov 15, 2026 by Tarquinen via check #257
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.

1 participant