Annotation of 43BSDReno/usr.bin/tbl/tf.c, revision 1.1.1.1

1.1       root        1: #ifndef lint
                      2: static char sccsid[] = "@(#)tf.c       4.2 8/11/83";
                      3: #endif
                      4: 
                      5:  /* tf.c: save and restore fill mode around table */
                      6: # include "t..c"
                      7: savefill()
                      8: {
                      9: /* remembers various things: fill mode, vs, ps in mac 35 (SF) */
                     10: fprintf(tabout, ".de %d\n",SF);
                     11: fprintf(tabout, ".ps \\n(.s\n");
                     12: fprintf(tabout, ".vs \\n(.vu\n");
                     13: fprintf(tabout, ".in \\n(.iu\n");
                     14: fprintf(tabout, ".if \\n(.u .fi\n");
                     15: fprintf(tabout, ".if \\n(.j .ad\n");
                     16: fprintf(tabout, ".if \\n(.j=0 .na\n");
                     17: fprintf(tabout, "..\n");
                     18: fprintf(tabout, ".nf\n");
                     19: /* set obx offset if useful */
                     20: fprintf(tabout, ".nr #~ 0\n");
                     21: fprintf(tabout, ".if n .nr #~ 0.6n\n");
                     22: }
                     23: rstofill()
                     24: {
                     25: fprintf(tabout, ".%d\n",SF);
                     26: }
                     27: endoff()
                     28: {
                     29: int i;
                     30:        for(i=0; i<MAXHEAD; i++)
                     31:                if (linestop[i])
                     32:                        fprintf(tabout, ".nr #%c 0\n", 'a'+i);
                     33:        for(i=0; i<texct; i++)
                     34:                fprintf(tabout, ".rm %c+\n",texstr[i]);
                     35: fprintf(tabout, "%s\n", last);
                     36: }
                     37: ifdivert()
                     38: {
                     39: fprintf(tabout, ".ds #d .d\n");
                     40: fprintf(tabout, ".if \\(ts\\n(.z\\(ts\\(ts .ds #d nl\n");
                     41: }
                     42: saveline()
                     43: {
                     44: fprintf(tabout, ".if \\n+(b.=1 .nr d. \\n(.c-\\n(c.-1\n");
                     45: linstart=iline;
                     46: }
                     47: restline()
                     48: {
                     49: fprintf(tabout,".if \\n-(b.=0 .nr c. \\n(.c-\\n(d.-%d\n", iline-linstart);
                     50: linstart = 0;
                     51: }
                     52: cleanfc()
                     53: {
                     54: fprintf(tabout, ".fc\n");
                     55: }

unix.superglobalmegacorp.com

This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.