#-h- pack.r 492 asc 24-apr-81 16:00:52 [002,100] #-h- main 430 asc 24-apr-81 16:00:46 [002,100] define(RIGHT_MARGIN,80) DRIVER(pack) character buf(MAXLINE), word(MAXLINE), obuf(MAXLINE) integer i, nxtcol integer getlin, getwrd call query("usage: pack.") call inpack(nxtcol, RIGHT_MARGIN, obuf, STDOUT) while (getlin(buf, STDIN) != EOF) { i = 1 while (getwrd(buf, i, word) > 0) call dopack(word, nxtcol, RIGHT_MARGIN, obuf, STDOUT) } call flpack(nxtcol, RIGHT_MARGIN, obuf, STDOUT) DRETURN end #-h- pack.rof 726 asc 08-may-81 16:59:13 [002,100] .pl 60 .bp .rm 70 .in 0 .he ;PACK;10/29/80;PACK; .fo ''-#-' .fi NAME .br .in 7 pack - pack words into columns .sp 1 .in SYNOPSIS .br .in 7 pack .sp 1 .in DESCRIPTION .br .in 7 pack takes the words (groups of characters separated by blanks or tabs) found on the standard input and outputs them to standard output in five columns, 16 spaces wide, ordered from left to right. The characters used to achieve the separation of columns are TAB characters, such that those terminals which support hardware tabs can be driven efficiently. .sp 1 .in FILES .br .in 7 .sp 1 .in SEE ALSO .br .in 7 .sp 1 .in DIAGNOSTICS .br .in 7 .sp 1 .in AUTHORS .br .in 7 Joe Sventek .sp 1 .in BUGS .br .in 7