nymea / nymea-app

A nymea frontend app

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Language settings issue on macOS

Boernsman opened this issue · comments

In macOS multiple preferred languages can be set. If I add German as system language then the nymea:app switches to German - primary system language is still English.

Please post the first few lines of the log. It prints locale info of the system

macOS prime system language English, second language German

nymea:app 1.0.140 running on "macbook-pro.home" "macOS Mojave (10.14)" "osx" "10.14"
Locale info: QLocale(English, Latin, Austria) "en_AT" QLocale::English QLocale(English, Latin, Austria)
Loaded translation for locale QLocale(English, Latin, Austria)ZeroConf: Created service browser for

--> Result app is in German

macOS prime system language English, no second language set

nymea:app 1.0.140 running on "macbook-pro.home" "macOS Mojave (10.14)" "osx" "10.14"
Locale info: QLocale(English, Latin, Austria) "en_AT" QLocale::English QLocale(English, Latin, Austria)
Failed to load translations for locale QLocale(English, Latin, Austria)

--> Result app is in English

Ok. I've looked into this... The reason why this happens:

you have as primary language "en_AT" set. Now it tries to load that and fails, because noone translated the app to "en_AT". There is "en_US" but that's not a good match, numbers and dates would show wrong.
So it moves on to the second option which is "de_AT". There isn't a "de_AT" either, however, there is a "de"... It loads that.

So that means "de_AT" matches closer to "de" than "en_AT" to "en_US".

I guess an option for this case would be to provide a translation for "en" translation... Not sure what else that might break tho...