android / wear-os-samples

Multiple samples showing best practices in app and watch face development on Wear OS.
https://developer.android.com/wear
Apache License 2.0
1.11k stars 572 forks source link

Use BitmapFonts for weather icons instead of multiple conditions with Images #1132

Closed amoledwatchfaces closed 3 months ago

amoledwatchfaces commented 3 months ago

We can use BitmapFonts element to specify set of weather icons for day / night.

This allows watchface.xml to be more readable & cleaner. It also helps reducing code by 50% and helps renderer as it does not need to compare many conditions. All while maintaining same functionality.

yschimke commented 3 months ago

Nice, seems like a smart change. I'll leave for @garanj to approve.

garanj commented 3 months ago

Hi @amoledwatchfaces apologies for the delay, you can see that the recent changes to the conditions enum have been reverted, so the highest value is now 15 - WINDY.

Would you be able to revisit your PR so that it only covers those cases, not up to 22?