sbase

suckless unix tools
git clone git://git.2f30.org/sbase
Log | Files | Refs | README | LICENSE

commit 160709734c6b0ad937d65159e9e723a488c0fc5c
parent 37eaf92a7dc19a7148843411fada7021e6507caa
Author: Hiltjo Posthuma <hiltjo@codemadness.org>
Date:   Sat,  7 Mar 2015 13:56:13 +0100

col.1: convert to mandoc

- Also fix a few typos, style and section order.
- Changed the text "800 characters per line" to "800 bytes per line" as col
  doesn't seem to support UTF-8 right now.

Diffstat:
Mcol.1 | 130+++++++++++++++++++++++++++++++++++++-------------------------------------------
1 file changed, 60 insertions(+), 70 deletions(-)

diff --git a/col.1 b/col.1 @@ -1,90 +1,80 @@ -.TH COL 1 col -.SH NAME -col - filter reverse line-feeds -.SH SYPNOSIS -.B col -.RB [ \-p ] -.RB [ \-b ] -.RB [ \-f ] -.RB [ \-x ] -.RB [ \-l -.IR num ] -.SH DESCRIPTION -.PP +.Dd March 6, 2014 +.Dt COL 1 +.Os sbase +.Sh NAME +.Nm col +.Nd filter reverse line-feeds +.Sh SYPNOSIS +.Nm +.Op Fl bfpx +.Op Fl l Ar num +.Sh DESCRIPTION The -.B col -utility filter all the reverse (and half reverse) line feeds, -as they are produced by nroff with .2C of ms(6) or by tbl(1). -.B col +.Nm +utility filters all the reverse (and half reverse) line feeds, +as they are produced by +.Xr nroff 1 +with .2C of +.Xr ms 6 +or by +.Xr tbl 1 . +.Nm also replaces spaces by tabs when it is possible. The control sequences managed by -.B col +.Nm are: -.TP -.B ESC-7 -reverse line-feed -.TP -.B ESC-8 -reverse half-line-feed -.TP -.B ESC-9 -forward half-line-feed -.TP -.B VT -vertical-tab -.TP -.B SP +.Bl -tag -width Ds +.It ESC-7 +Reverse line-feed +.It ESC-8 +Reverse half-line-feed +.It ESC-9 +Forward half-line-feed +.It VT +Vertical-tab +.It SP Space -.TP -.B TAB -horizontal tab -.TP -.B RETURN +.It TAB +Horizontal tab +.It RETURN Carriage return -.TP -.B NL +.It NL New line -.PP +.El +.Pp All the other control codes and escape sequences are removed. -.B Col -transform all the spaces into tabulators. -.SH OPTIONS -.TP -.B \-p +.Nm +transforms all the spaces into tabulators. +.Sh OPTIONS +.Bl -tag -width Ds +.It Fl p Print unknown escape sequences to the output. -.TP -.B \-b +.It Fl b Do not print backspaces in output, -and Print only the last overstriked character in the output. -.TP -.B \-f +and print only the last overstriked character in the output. +.It Fl f Allow forward half line feeds in the output. -.TP -.B \-x +.It Fl x Do not convert spaces in tabulators. -.TP -.BI \-l " num" +.It Fl l Ar num Increment to -.I num +.Ar num the number of lines buffered for -.B col. -.SH BUGS -.PP -.B Col -only process text with a maximum of 256 lines with 800 characteres per line, -although the number of lines can be modified with -.B \-l +.Nm +.El +.Sh SEE ALSO +.Xr nroff 1 , +.Xr tbl 1 , +.Xr ms 6 +.Sh BUGS +.Nm +only process text with a maximum of 256 lines with 800 bytes per line, +although the number of lines can be modified with the +.Fl l option. When the number of lines is bigger, the buffer is flushed to the output, so new reverse line feeds can not operate in the flushed lines. This implementation ignores SI and SO selection character sets, -because it is supposed it will work only with UTF-8 strings, +because it is supposed to work only with UTF-8 strings, although the UTF-8 support is missed. -.SH SEE ALSO -.BR nroff (1), -.BR ms (6), -.BR tbl(1). - - -