xref: /csrg-svn/usr.bin/ptx/ptx.1 (revision 48290)
1*48290Sbostic.\" Copyright (c) 1990 The Regents of the University of California.
2*48290Sbostic.\" All rights reserved.
319448Smckusick.\"
4*48290Sbostic.\" %sccs.include.proprietary.roff%
543083Scael.\"
6*48290Sbostic.\"	@(#)ptx.1	6.6 (Berkeley) 04/18/91
7*48290Sbostic.\"
847378Scael.Vx
943083Scael.Dd
1043083Scael.Dt PTX 1
1143083Scael.Os ATT 7th
1243083Scael.Sh NAME
1343083Scael.Nm ptx
1443083Scael.Nd permuted index
1543083Scael.Sh SYNOPSIS
1643083Scael.Nm ptx
1743083Scael.Op  option
1843083Scael\&...
1944957Scael.Op input [output]
2043083Scael.Sh DESCRIPTION
2143083Scael.Nm Ptx
2219448Smckusickgenerates a permuted index to file
2343083Scael.Ar input
2419448Smckusickon file
2543083Scael.Ar output
2619448Smckusick(standard input and output default).
2719448SmckusickIt has three phases: the first does the permutation, generating
2819448Smckusickone line for each keyword in an input line.
2919448SmckusickThe keyword is rotated to the front.
3019448SmckusickThe permuted file is then
3119448Smckusicksorted.
3219448SmckusickFinally, the sorted lines are rotated so the keyword
3319448Smckusickcomes at the middle of the page.
3443083Scael.Nm Ptx
3519448Smckusickproduces output in the form:
3643083Scael.Pp
3743083Scael.Dl \&.xx "tail" "before keyword" "keyword and after" "head"
3843083Scael.Pp
3919448Smckusickwhere .xx may be an
4043083Scael.Xr nroff 1
4119448Smckusickor
4243083Scael.Xr troff  1
4319448Smckusickmacro
4419448Smckusickfor user-defined formatting.
4519448SmckusickThe
4643083Scael.Ar before keyword
4719448Smckusickand
4843083Scael.Ar keyword and after
4919448Smckusickfields incorporate as much of the line as will fit
5019448Smckusickaround the keyword when it is printed at the middle of the page.
5143083Scael.Ar Tail
5219448Smckusickand
5343083Scael.Ar head ,
5419448Smckusickat least one of which is an empty string "",
5519448Smckusickare wrapped-around pieces small enough to fit
5619448Smckusickin the unused space at the opposite end of the line.
5719448SmckusickWhen original text must be discarded, `/' marks the spot.
5843083Scael.Pp
5919448SmckusickThe following options can be applied:
6043083Scael.Tw Fl
6143083Scael.Tp Fl f
6219448SmckusickFold upper and lower case letters for sorting.
6343083Scael.Tp Fl t
6419448SmckusickPrepare the output for the phototypesetter;
6519448Smckusickthe default line length is 100 characters.
6643083Scael.Tp Cx Fl w
6743083Scael.Ws
6843083Scael.Ar n
6943083Scael.Cx
7019448SmckusickUse the next argument,
7143083Scael.Ar n ,
7219448Smckusickas the width of the output line.
7319448SmckusickThe default line length is 72 characters.
7443083Scael.Tp Cx Fl g
7543083Scael.Ws
7643083Scael.Ar n
7743083Scael.Cx
7819448SmckusickUse the next argument,
7943083Scael.Ar n ,
8019448Smckusickas the number of characters to allow for each gap
8119448Smckusickamong the four parts of the line as finally printed.
8219448SmckusickThe default gap is 3 characters.
8343083Scael.Tp Cx Fl o
8443083Scael.Ws
8543083Scael.Ar only
8643083Scael.Cx
8743083ScaelUse as keywords only the words given in the
8843083Scael.Ar only
8943083Scaelfile.
9043083Scael.Tp Cx Fl i
9143083Scael.Ws
9243083Scael.Ar ignore
9343083Scael.Cx
9419448SmckusickDo not use as keywords any words given in the
9519448Smckusickignore
9619448Smckusickfile.
9743083ScaelIf the
9843083Scael.Fl i
9943083Scaeland
10043083Scael.Fl o
10143083Scaeloptions are missing, use
10243083Scael.Pa /usr/share/dict/eign
10343083Scaelas the
10419448Smckusickignore
10519448Smckusickfile.
10643083Scael.Tp Cx Fl b
10743083Scael.Ws
10843083Scael.Ar break
10943083Scael.Cx
11043083ScaelUse the characters in the
11119448Smckusickbreak
11219448Smckusickfile to separate words.
11319448SmckusickIn any case, tab, newline, and space characters are always used as break characters.
11443083Scael.Tp Fl r
11519448SmckusickTake any leading nonblank characters of each input line to
11619448Smckusickbe a reference identifier (as to a page or chapter)
11719448Smckusickseparate from the text of the line.
11819448SmckusickAttach that identifier as a 5th field on each output line.
11943083Scael.Tp
12043083Scael.Pp
12119448SmckusickThe index for this manual was generated using
12243083Scael.Nm ptx .
12343083Scael.Sh FILES
12443083Scael.Dw /usr/share/dict.eign
12543083Scael.Di L
12643083Scael.Dp /usr/bin/sort
12743083Scael.Dp /usr/share/dict/eign
12843083Scael.Dp
12943083Scael.Sh HISTORY
13043083Scael.Nm Ptx
13143083Scaelappeared in Version 7 AT&T UNIX
13243083Scael.Sh BUGS
13319448SmckusickLine length counts do not account for overstriking or
13419448Smckusickproportional spacing.
135