Draw a clock: Difference between revisions

m
Replace deprecated functions
imported>Mparson
(graphical analog clock in yabasic)
m (Replace deprecated functions)
 
(One intermediate revision by one other user not shown)
Line 6,198:
clear(curr_win, BACKGROUND);
KEYBOARD := GRAPH_KEYBOARD;
command := busy_getcgetc(KEYBOARD, NO_WAIT);
while command <> 'q' do
start_time := truncToSecond(time(NOW));
Line 6,240:
fcircle(100, 100, 7, CLOCKCOLOR);
circle(100, 100, 7, FOREGROUND);
DRAW_FLUSHflushGraphic;
await(start_time + 1 . SECONDS);
command := busy_getcgetc(KEYBOARD, NO_WAIT);
end while;
end func;</syntaxhighlight>
Line 6,721:
 
=={{header|Yabasic}}==
===digital clock===
<syntaxhighlight lang="yabasic">clear screen
open window 300,100
Line 6,756 ⟶ 6,757:
end if</syntaxhighlight>
 
=={{header|Yabasic}} (=graphical analog clock)===
<syntaxhighlight lang="yabasic">
#!/usr/bin/yabasic
29

edits