Localization
The launcher is localized via classic .resx resources. Files live in sources/launcher/Stride.Launcher/Assets/Localization/.
File layout
| File | Role |
|---|---|
Strings.resx |
UI strings — default (English) |
Strings.ja-JP.resx |
Japanese translations |
Strings.Designer.cs |
Auto-generated static accessors for Strings.* |
Urls.resx |
External URLs — default |
Urls.ja-JP.resx |
Japanese URL overrides (e.g. localized documentation) |
Urls.Designer.cs |
Auto-generated static accessors for Urls.* |
Both .resx files are EmbeddedResource; the .Designer.cs files are regenerated by the PublicResXFileCodeGenerator tool whenever the .resx is saved in Visual Studio. Keep the designer files committed so command-line builds (and non-Windows contributors) don't need to rerun the generator.
Strings and Urls expose public static getters (e.g. Strings.AskInstallVersion, Urls.RssFeed). Use them from view models — never hard-code user-facing strings or external URLs.
Adding a string
- Open
Strings.resxin Visual Studio (or edit the XML directly). - Add the new entry with a descriptive key and English value.
- Add the same key to every sibling file (
Strings.ja-JP.resx, …). Leave the value in English if no translation is available; Crowdin (see below) will pick it up. - Rebuild to regenerate
Strings.Designer.cs(or edit both the.resxand the designer by hand on Linux). - Use
Strings.MyNewKeyin code.
For format strings, include named or positional placeholders ({0}, {1}) and use string.Format(Strings.MyFormat, value1, value2) in code.
Adding a URL
Same procedure, but in Urls.resx. Every URL the launcher opens must come from here so it can be localized and pinned per branch — see Strings.DownloadPage, Urls.RssFeed, Urls.GettingStarted, etc.
URLs that take a version placeholder (documentation, release notes) typically contain {0} and are formatted at call time with the active version's major.minor.
Adding a language
- Create
Strings.{locale}.resx(e.g.Strings.fr-FR.resx) andUrls.{locale}.resxnext to the existing files. - Update Stride.Launcher.csproj to declare them as
EmbeddedResource(follow the pattern used forStrings.ja-JP.resx). - Avalonia does not have a built-in language picker in the launcher — the OS UI culture determines the selected locale via standard .NET satellite assembly resolution.
Translations workflow
The repository includes crowdin.yml at the root, meaning user-facing .resx files can be synced with Crowdin. Check that file for which paths are actually covered before renaming or moving a .resx.