OpenTracks icon indicating copy to clipboard operation
OpenTracks copied to clipboard

Corsican localization is now ready on Weblate

Open Patriccollu opened this issue 1 year ago • 5 comments

Hello,

I just completed the Corsican localization of opentracks-opentracks-src-main-res-values-strings-xml-main file on Weblate.

Please note that two other files - App store metadata and glossary do not contain any string to translate.

Best regards, Patriccollu.

Patriccollu avatar Aug 20 '24 22:08 Patriccollu

Merged localization, but we still need a language switcher as Android's built-in doesn't pick up Corsican. See: https://github.com/OpenTracksApp/OpenTracks/issues/1970#issuecomment-2295355736

Actually, this might even be considered a bug in Android.

dennisguse avatar Aug 27 '24 20:08 dennisguse

Hope that you will be able to circumvent this problem by setting co locale programmatically!

Patriccollu avatar Aug 28 '24 20:08 Patriccollu

Hi @dennisguse,

Do yoy have some news on this enhancement?

Best regards, Patriccollu.

Patriccollu avatar Oct 06 '24 17:10 Patriccollu

Sadly no. Times are quite busy. I should have time at the end of the year. My plan was to use the approach taken by K9-mail and just copy their implementation - what could go wrong, right?

dennisguse avatar Oct 06 '24 17:10 dennisguse

I can confirm that Corsican language can be selected on K9-Mail app.

Patriccollu avatar Oct 06 '24 23:10 Patriccollu

Just stumbled upon this: https://apt.izzysoft.de/fdroid/index/apk/io.nightdavisao.multilocale

Would it help to make Corsican locale selectable? Haven't had time to test myself.

pstorch avatar Nov 13 '24 15:11 pstorch

@pstorch this tool needs root access.

dennisguse avatar Nov 14 '24 23:11 dennisguse

@dennisguse there is also an option to grant permission via ADB. I want to try that.

pstorch avatar Nov 15 '24 06:11 pstorch

I could give the app permission via adb, but it doesn't offer Corsican locale either.

pstorch avatar Nov 15 '24 22:11 pstorch

@Patriccollu feature is available as of v4.15.0 (will take some days for F-Droid). However, only for Android 14 (SDK34+) or later - the commit messages says SDK33+, but that is a mistake on my side. I couldn't figure out a way to get the list of available locales/languauges prior Android versions and I didn't want to manually set those somewhere. Hope this works for you - if not we can keep digging :D

dennisguse avatar Dec 01 '24 10:12 dennisguse

@dennisguse I need to find an Android 14 device to be able to test as my current phone is only 11 :-(

Thank you for your work on this issue. I will keep you informed.

Patriccollu avatar Dec 06 '24 10:12 Patriccollu

@Patriccollu The reason for this is an API that lists the available locales that were bundled with the application. Sadly, this API is only available on Android 14 or later. Otherwise, we would manually need to maintain the lists of locales in the source code in addition to the actually translations from Weblate.

I also checked for alternatives (like LocaleManagerCompat.getApplicationLocales()), but those don't provide not all locales.

dennisguse avatar Dec 08 '24 21:12 dennisguse

@dennisguse And what about the option to use the approach taken by K9-mail?

1733696173576

Patriccollu avatar Dec 08 '24 22:12 Patriccollu

Let's see...

dennisguse avatar Dec 10 '24 21:12 dennisguse

@Patriccollu should work now.. Implementation is brutally ugly, but hey it works and the locales will be updated automatically. We are not a beauty contest, right? ¯_(ツ)_/¯

dennisguse avatar Dec 11 '24 21:12 dennisguse

Hi @dennisguse ,

It's just... perfect! ;-)

Thanks a lot, Patriccollu. Screenshot_2024-12-12-14-11-29-135_de dennisguse opentracks nightly

Patriccollu avatar Dec 12 '24 13:12 Patriccollu