We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
My Windows is set to German. lang.SystemLocale() returns de-DE-Latn
lang.SystemLocale()
de-DE-Latn
I created a en.json and a de.json file in my translation folder.
en.json
de.json
I get the following error message when running: Cause: message "translation-key" not found in language "br"
Cause: message "translation-key" not found in language "br"
however, i never created a br language, and my PC was never set to br.
br
No response
package main import ( "fyne.io/fyne/v2/app" "fyne.io/fyne/v2/widget" "fyne.io/fyne/v2/lang" "embed" ) //go:embed translations var Translations embed.FS func main() { lang.AddTranslationsFS(Translations, "translations") a := app.New() w := a.NewWindow("Hello World") w.SetContent(widget.NewLabel(lang.L("MyLabel"))) w.ShowAndRun() }
bed23d9
1.22.5
Windows 11
My current guess is that the languages are worked through in order.
Since fyne includes translations for BR, EN, FR, pt_BR and SV, it first tries BR before DE because that comes before DE in the ABC.
When i create a br.json in my application, it works but takes the translation from the br.json instead of de.json
br.json
The text was updated successfully, but these errors were encountered:
Bugfix finding closest supported language with app translations.
01a394c
fyne-io#5015
Fixed on the release branch, thanks so much @Sharrnah :)
Sorry, something went wrong.
No branches or pull requests
Checklist
Describe the bug
My Windows is set to German.
lang.SystemLocale()
returnsde-DE-Latn
I created a
en.json
and ade.json
file in my translation folder.I get the following error message when running:
Cause: message "translation-key" not found in language "br"
however, i never created a
br
language, and my PC was never set tobr
.How to reproduce
Screenshots
No response
Example code
Fyne version
bed23d9
Go compiler version
1.22.5
Operating system and version
Windows 11
Additional Information
My current guess is that the languages are worked through in order.
Since fyne includes translations for BR, EN, FR, pt_BR and SV,
it first tries BR before DE because that comes before DE in the ABC.
When i create a
br.json
in my application, it works but takes the translation from thebr.json
instead ofde.json
The text was updated successfully, but these errors were encountered: