Browse Source

c'est l'heure de la pizza

master
tth 3 years ago
parent
commit
c462c9ad91
1 changed files with 4 additions and 11 deletions
  1. +4
    -11
      viz/curses/t.c

+ 4
- 11
viz/curses/t.c View File

@ -17,24 +17,17 @@ int loop, idx, c, p;
char ligne[100];
for (idx=0; idx<10; idx++) {
c = '0'+idx;
p = 1+(idx*9);
aff7segs_digit(stdscr, 4, p, c);
mvaddch(3, p, c);
}
for (loop=0; loop<nbl; loop++) {
sprintf(ligne, "%5d", loop);
mvaddstr(15, 1, ligne);
mvaddstr(2, 1, ligne);
for (idx=0; idx<strlen(ligne); idx++) {
aff7segs_digit(stdscr, 16, 8+(idx*9), ligne[idx]);
aff7segs_digit(stdscr, 3, 10+(idx*9), ligne[idx]);
}
sprintf(ligne, "%.3f", drand48());
mvaddstr(26, 1, ligne);
mvaddstr(12, 1, ligne);
for (idx=0; idx<strlen(ligne); idx++) {
aff7segs_digit(stdscr, 27, 8+(idx*9), ligne[idx]);
aff7segs_digit(stdscr, 13, 10+(idx*9), ligne[idx]);
}
refresh();


Loading…
Cancel
Save