CorvetteCole / PixelWatchFace

A minimalistic and open-source watchface for WearOS
GNU General Public License v3.0
73 stars 15 forks source link

Rework of time and date formatting #50

Closed Daninator1 closed 4 years ago

Daninator1 commented 4 years ago

This PR changes the way time and date gets formatted. It now uses the device's locale to generate the according localized strings. This also fixes some abbreviation mistakes for some languages (e.g. German). As a result, I removed the time and date formatting settings from the companion app as I think these settings should depend on the device's locale (can be discussed, however). The temperature decimal separator now also gets chosen according to the current locale instead of hardcoding it.

CorvetteCole commented 4 years ago

This looks like a great improvement and is very thorough! I am impressed that you braved through the phone app for this. It is going through a full rework for the next release since it is totally terrible being monolithic and all.

I will put this through some testing and then merge the PR, thanks for the contribution! (p.s. if you need a weather unlock code drop me a line contributed@corvettecole.com)

Daninator1 commented 4 years ago

Mostly had to touch the wear app anyways, on the phone app I just removed everything related to the now unused settings. Glad I could help! 🙂

Regarding the weather code, I already bought the iap on the play store, is there a way I can debug using the emulator without logging in with my personal google account?

CorvetteCole commented 4 years ago

Yes there is. If you go to the Settings.class in the watch app you can change the default value for "advanced" to true where it loads the settings. I can give a line number if needed

CorvetteCole commented 4 years ago

I've merged this PR, thanks for your contribution

CorvetteCole commented 3 years ago

This has caused a major bug in some locales where AM and PM are appended to the main time display and go off screen. I am patching that behavior out

CorvetteCole commented 3 years ago

fixed it by matching lowercase and uppercase A-Z characters in the regex string, should've caught this earlier! Thanks for the contribution