ploot

plot images or real-time plain text from a .csv file
Log | Files | Refs | README

commit 8321d90e92e7e25c50844e48f758be3b72f98a68
parent d7624d60484f10f1473317b508ff481b8acc1ae9
Author: Josuah Demangeon <mail@josuah.net>
Date:   Mon,  7 May 2018 03:22:27 +0200

add a -w width flag to fill up a whole TV if wanted

Diffstat:
Mplootxt.c | 11++++++++---
1 file changed, 8 insertions(+), 3 deletions(-)

diff --git a/plootxt.c b/plootxt.c @@ -200,7 +200,7 @@ fmt_labels(char out[LINE_MAX], int ncol, char *labels[LINE_MAX / 2]) static void usage(void) { - fprintf(stderr, "usage: %s maxval... <csv\n", argv0); + fprintf(stderr, "usage: [-w width] %s maxval... <csv\n", argv0); exit(1); } @@ -209,8 +209,13 @@ parse_args(int argc, char **argv, double *max) { int n; - argv0 = *argv; - argv++, argc--; + ARGBEGIN { + case 'w': + wflag = atoi(EARGF(usage())); + break; + default: + usage(); + } ARGEND; if (argc == 0) usage();