DD2-monitor/viz/curses/vumetre.c

37 lines
711 B
C
Raw Normal View History

/*
* DD2 Monitoring
*
* ncurses seven segment display
*/
#include <stdio.h>
#include <stdlib.h>
#include <strings.h>
#include <getopt.h>
#include <ncurses.h>
#include "ecran.h"
int verbosity;
/* ---------------------------------------------------------------- */
int vumetre_0(WINDOW *win, int lig, int col, float val, int larg)
{
int foo;
#if DEBUG_LEVEL
fprintf(stderr, ">>> %s ( %p %d %d %f %d )\n",
__func__, win, lig, col, val, larg);
#endif
for (foo=0; foo<larg; foo++) {
mvwaddch(win, lig-1, col+foo, '*');
wrefresh(win);
}
return -1;
}
/* ---------------------------------------------------------------- */
/* ---------------------------------------------------------------- */