Slint 1.7 Released with New Widgets, Multi-Window Support, and Live-Preview Redesign (slint.dev)
from hunger@programming.dev to programming@programming.dev on 18 Jul 2024 12:58
https://programming.dev/post/17025926

#programming

threaded - newest

ChaoticNeutralCzech@feddit.org on 18 Jul 2024 13:17 next collapse

12-hour time idiocy strikes again… Normalize clocks with numbers 0-11, dammit!

RageAgainstTheRich@lemmy.world on 18 Jul 2024 14:58 collapse

There is clocks that say 0 instead of 12? The fuck?

ChaoticNeutralCzech@feddit.org on 18 Jul 2024 20:14 collapse

It’s more logical. The reason it’s 12 is because the Romans were afraid of zeros. The “12” means either 0 hours or 12 hours after midnight while 1-11 mean 1-11 or 13-23 hours after midnight.

if (pm && numberOnClock != 12) hoursSinceMidnight = numberOnClock+12; 
else /*am or 12pm*/ 
{ 
  if (numberOnClock == 12 /*12am*/) hoursSinceMidnight = 0; 
  else /*1-11 am or 12pm*/ hoursSinceMidnight=numberOnClock; 
}

If a “0” was on top, it would be

if (pm) hoursSinceMidnight=numberOnClock+12; 
else /*am*/ hoursSinceMidnight=numberOnClock; 

TL;DR: Swap the 0 and 12 on the clock face. The inner (AM) ring now has numbers 0-11 while the outer (PM) ring has numbers 12-23. Things now make sense. We should have done this centuries ago instead of manufacturing measuring instruments whose scale starts at 12 rather than 0.

vext01@lemmy.sdf.org on 18 Jul 2024 16:38 collapse

I really dislike those clock widgets. I have them on my phone for setting alarms. Much harder than just typing the time in.

wizardbeard@lemmy.dbzer0.com on 18 Jul 2024 19:09 collapse

At least on my android, if I tap the numbers at the top it allows me to just type it in.

vext01@lemmy.sdf.org on 18 Jul 2024 19:37 collapse

Thankfully you can, yeah.