diff options
Diffstat (limited to 'tools/h5dump')
-rw-r--r-- | tools/h5dump/h5dump.c | 18 |
1 files changed, 15 insertions, 3 deletions
diff --git a/tools/h5dump/h5dump.c b/tools/h5dump/h5dump.c index 5d3db21..a8b6832 100644 --- a/tools/h5dump/h5dump.c +++ b/tools/h5dump/h5dump.c @@ -649,7 +649,9 @@ usage(const char *prog) fprintf(stdout, " -o F, --output=F Output raw data into file F\n"); fprintf(stdout, " -b B, --binary=B Binary file output, of form B\n"); fprintf(stdout, " -t P, --datatype=P Print the specified named datatype\n"); - fprintf(stdout, " -w N, --width=N Set the number of columns of output\n"); + fprintf(stdout, " -w N, --width=N Set the number of columns of output. A value of 0 (zero)\n"); + fprintf(stdout, " sets the number of columns to the maximum (65535).\n"); + fprintf(stdout, " Default width is 80 columns.\n"); fprintf(stdout, " -m T, --format=T Set the floating point output format\n"); fprintf(stdout, " -q Q, --sort_by=Q Sort groups and attributes by index Q\n"); fprintf(stdout, " -z Z, --sort_order=Z Sort groups and attributes by order Z\n"); @@ -2377,7 +2379,12 @@ dump_data(hid_t obj_id, int obj_data, struct subset_t *sset, int display_index) outputformat->fmt_float = fp_format; } - outputformat->line_ncols = nCols; + if (nCols==0) { + outputformat->line_ncols = 65535; + outputformat->line_per_line = 1; + } + else + outputformat->line_ncols = nCols; outputformat->do_escape=display_escape; /* print the matrix indices */ outputformat->pindex=display_index; @@ -5363,7 +5370,12 @@ xml_dump_data(hid_t obj_id, int obj_data, struct subset_t UNUSED * sset, int UNU int depth; int stdindent = COL; /* should be 3 */ - outputformat->line_ncols = nCols; + if (nCols==0) { + outputformat->line_ncols = 65535; + outputformat->line_per_line = 1; + } + else + outputformat->line_ncols = nCols; indent += COL; /* |