forked from FOSS/BangleApps
V0.03 - Use theme of bangle.
parent
18c3df9b91
commit
79db8ba05d
|
@ -1,2 +1,3 @@
|
|||
0.01: New App!
|
||||
0.01: New App.
|
||||
0.02: Use build in function for steps and other improvements.
|
||||
0.03: Adapt colors based on the theme of the user.
|
|
@ -2,15 +2,23 @@
|
|||
|
||||

|
||||
|
||||
|
||||
## Fullscreen mode
|
||||
In the settings, fullscreen mode can be enabled and disabled:
|
||||
|
||||

|
||||
|
||||
Additionally, in fullscreen mode a lock icon can be shown...
|
||||
If you installed the "alarm" app, you can directly set a timer. Simply tab at
|
||||
|
||||
## Custom theme
|
||||
If you switch the light/dark theme on your bangle, the design changes accordingly:
|
||||
|
||||

|
||||
|
||||
## Other features
|
||||
- Lock icon: Show lock icon in fullscreen mode
|
||||
- Timer: If you installed the "alarm" app, you can directly set a timer. Simply tab at
|
||||
top / bottom of the screen.
|
||||
|
||||
|
||||
## Thanks to
|
||||
<a href="https://www.flaticon.com/free-icons/lock" title="lock icons">Lock icons created by Those Icons - Flaticon</a>
|
||||
|
||||
|
|
|
@ -138,13 +138,13 @@ function draw() {
|
|||
var yOffset = settings.fullscreen ? 0 : 10;
|
||||
var y = H/5*2 + yOffset;
|
||||
g.reset().clearRect(0,0,W,W);
|
||||
g.setColor("#000");
|
||||
g.setColor(g.theme.fg);
|
||||
g.fillRect(0,y,W,H);
|
||||
|
||||
// Draw date
|
||||
y -= settings.fullscreen ? 5 : 0;
|
||||
var date = new Date();
|
||||
g.setColor("#000");
|
||||
g.setColor(g.theme.fg);
|
||||
g.setFontAlign(1,1);
|
||||
g.setLargeFont();
|
||||
var dateStr = date.getDate();
|
||||
|
@ -157,7 +157,7 @@ function draw() {
|
|||
g.drawString(locale.month(date, 1), W/2 + 10, y+1);
|
||||
|
||||
// Draw time
|
||||
g.setColor("#fff");
|
||||
g.setColor(g.theme.bg);
|
||||
g.setLargeFont();
|
||||
g.setFontAlign(0,-1);
|
||||
var timeStr = locale.time(date,1);
|
||||
|
@ -174,7 +174,7 @@ function draw() {
|
|||
|
||||
// Draw lock
|
||||
if(settings.showLock && Bangle.isLocked()){
|
||||
g.setColor("#000");
|
||||
g.setColor(g.theme.bg);
|
||||
g.drawImage(imgLock, 2, 2);
|
||||
}
|
||||
|
||||
|
@ -189,7 +189,9 @@ function draw() {
|
|||
Bangle.loadWidgets();
|
||||
|
||||
// Clear the screen once, at startup
|
||||
g.setTheme({bg:"#fff",fg:"#000",dark:false}).clear();
|
||||
var bgOrig = g.theme.bg
|
||||
var fgOrig = g.theme.fg
|
||||
g.setTheme({bg:fgOrig,fg:bgOrig}).clear();
|
||||
// draw immediately at first, queue update
|
||||
draw();
|
||||
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
{
|
||||
"id": "bwclk",
|
||||
"name": "BlackWhite Clock",
|
||||
"version": "0.02",
|
||||
"version": "0.03",
|
||||
"description": "Black and white clock.",
|
||||
"readme": "README.md",
|
||||
"icon": "app.png",
|
||||
|
|
Binary file not shown.
After Width: | Height: | Size: 2.9 KiB |
Loading…
Reference in New Issue