deltachat / deltachat-android

Email-based instant messaging for Android.
GNU General Public License v3.0
1.1k stars 144 forks source link

use system language, support per-app-language-selection #3241

Closed r10s closed 2 weeks ago

r10s commented 3 weeks ago

this PR let's the app always just use the system language, removing the in-app language selection.

if the user wants to have Delta Chat in a different language, they can change the system language. since android13, it is even possible to do that per app. however, as "on the wire" things are neutral now and important strings are rendered in the receivers language, there is not much need to use sth. else than the system language.

sure, there may be cornercases, however, they're outweighed by the advantages:

github-actions[bot] commented 3 weeks ago

To test the changes in this pull request, install this apk: 📦 app-preview.apk

r10s commented 3 weeks ago

it needs to be tested if using a per-app language on android13/android14 is working

adbenitez commented 3 weeks ago

the information about per-app language is here: https://developer.android.com/guide/topics/resources/app-languages

instructions on how to add support for it to the apps is here: https://developer.android.com/guide/topics/resources/app-languages#auto-localeconfig

github-actions[bot] commented 3 weeks ago

To test the changes in this pull request, install this apk: 📦 app-preview.apk

r10s commented 3 weeks ago

thanks for the links, very helpful. i added a commit, in-app-language-selection works for me in the emulator with that :)

adbenitez commented 3 weeks ago

indeed, just tested in my device, now when I go to "App info" (clicking the app icon from the "recent used apps" / tasks manager) it shows the language selector of the app now integrated in the system! changing language there works as expected

image

r10s commented 3 weeks ago

ftr: another way to select the language is "System Settings / System / Languages / App languages":

Screenshot 2024-08-16 at 23 34 50

AndroidX also shows a way to again use an in-app language selector, while probably more straight-forward as before, it is still some stuff, so i do not think it is worth the effort, esp. as the user base that can use the new method is growing (according to gplay currently already 50%)

github-actions[bot] commented 3 weeks ago

To test the changes in this pull request, install this apk: 📦 app-preview.apk