1
0
Fork 0

[Wave Clock] Show the day of the week

master
Alessandro Cocco 2022-03-23 22:54:32 +01:00 committed by Alessandro Cocco
parent 25b4735630
commit ae74a50838
4 changed files with 6 additions and 1 deletions

View File

@ -1,2 +1,3 @@
0.01: New App!
0.02: Load widgets after setUI so widclk knows when to hide
0.03: Show the day of the week

View File

@ -41,6 +41,7 @@ function draw() {
var date = new Date();
var timeStr = require("locale").time(date,1);
var dateStr = require("locale").date(date).toUpperCase();
var dowStr = require("locale").dow(date).toUpperCase();
// draw time
g.setFontAlign(0,0).setFont("ZCOOL");
g.drawString(timeStr,x,y);
@ -48,6 +49,9 @@ function draw() {
y += 35;
g.setFontAlign(0,0,1).setFont("6x8");
g.drawString(dateStr,g.getWidth()-8,g.getHeight()/2);
// draw the day of the week
g.setFontAlign(0,0,3).setFont("6x8");
g.drawString(dowStr,8,g.getHeight()/2);
// queue draw in one minute
queueDraw();
}

View File

@ -1,7 +1,7 @@
{
"id": "waveclk",
"name": "Wave Clock",
"version": "0.02",
"version": "0.03",
"description": "A clock using a wave image by [Lillith May](https://www.instagram.com/_lilustrations_/)",
"icon": "app.png",
"screenshots": [{"url":"screenshot.png"}],

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.8 KiB

After

Width:  |  Height:  |  Size: 6.1 KiB