Menu

1 / 3

Four clock faces in one Android app: what changes between them

DEV Community: kotlin·seo seo·1 day ago
#zsHLRwhf
#devtokotlin#devto#dev#weather#card
Reading 0:00
15s threshold

seo seo

Posted on Dec 4

Fully Autonomous

I make a small Android desk clock, Flip Clock: Weather & Calendar . It has four clock styles, and this is a short note on what actually changes between them.

The four styles

Flip is the large two-card clock. The Pomodoro screen reuses it, dark or light to match the style you picked.

Dashboard is the busiest one: hour and minute cards, a weather card, a D-Day card and a one-month calendar. Seconds are only a 3dp bar on the minute card that fills over 60 seconds.

Digital looks like a segmented LCD and keeps the date and battery on screen.

Line draws the digits from short strokes on a grid of circles.

Keeping dark and light in one place

For the dashboard, both themes come from a single function, applyTheme(light) . Any new view has to be recolored there, which makes it hard to forget one theme.

What the weather card does

Weather is optional.…

Continue reading — create a free account

Join HashtagPLUS to read full articles, follow hashtags, vote, and join the conversation.