home *** CD-ROM | disk | FTP | other *** search
- /* ==( bench/alignrep.c )== */
-
- /* ----------------------------------------------- */
- /* Pro-C Copyright (C) 1988 - 1990 Vestronix Inc. */
- /* Modification to this source is not supported */
- /* by Vestronix Inc. */
- /* All Rights Reserved */
- /* ----------------------------------------------- */
- /* Written Nig 1-Jan-87 */
- /* Modified Geo 4-Oct-89 See comments below */
- /* ----------------------------------------------- */
- /* %W% (%H% %T%) */
-
- /*
- * Modifications
- *
- * 4-Nov-89 Geo - V2 version
- * 25-Oct-89 Geo - 1.32 Merge
- */
-
- # include <stdio.h>
- # include <bench.h>
- # include <prt.h>
-
- /* Function prototypes */
- static PROTO (void dsp_col, (int, int));
-
- /*
- * Helps user to align report stationary
- * with printer top of form
- */
- void align_report(replen, repwidth)
- int replen, repwidth;
- {
- int i;
-
- underln_p(1, 1, P_NORMAL, repwidth);
- center_p(1, 1, P_BOLD, repwidth, " TOF ");
-
- for(i = 0; i < repwidth; i++)
- dsp_col(3, i + 1);
-
- underln_p(replen, 1, P_NORMAL, repwidth);
- center_p(replen, 1, P_BOLD, repwidth, " BOF ");
-
- flushprt();
- clear_p();
- }
-
- static void dsp_col(line, col)
- int line, col;
- {
- char colstr[5];
- int ctr;
-
- sprintf(colstr, "%3d", col);
- for(ctr = 0; ctr < 3; ctr++)
- poke_p(line + ctr, col, P_NORMAL, colstr[ctr]);
- }
-