1.\" Copyright (c) 1990 Regents of the University of California. 2.\" All rights reserved. The Berkeley software License Agreement 3.\" specifies the terms and conditions for redistribution. 4.\" 5.\" @(#)ptx.1 6.4 (Berkeley) 07/24/90 6.\" 7.Dd 8.Dt PTX 1 9.Os ATT 7th 10.Sh NAME 11.Nm ptx 12.Nd permuted index 13.Sh SYNOPSIS 14.Nm ptx 15.Op option 16\&... 17.Op input [output] 18.Sh DESCRIPTION 19.Nm Ptx 20generates a permuted index to file 21.Ar input 22on file 23.Ar output 24(standard input and output default). 25It has three phases: the first does the permutation, generating 26one line for each keyword in an input line. 27The keyword is rotated to the front. 28The permuted file is then 29sorted. 30Finally, the sorted lines are rotated so the keyword 31comes at the middle of the page. 32.Nm Ptx 33produces output in the form: 34.Pp 35.Dl \&.xx "tail" "before keyword" "keyword and after" "head" 36.Pp 37where .xx may be an 38.Xr nroff 1 39or 40.Xr troff 1 41macro 42for user-defined formatting. 43The 44.Ar before keyword 45and 46.Ar keyword and after 47fields incorporate as much of the line as will fit 48around the keyword when it is printed at the middle of the page. 49.Ar Tail 50and 51.Ar head , 52at least one of which is an empty string "", 53are wrapped-around pieces small enough to fit 54in the unused space at the opposite end of the line. 55When original text must be discarded, `/' marks the spot. 56.Pp 57The following options can be applied: 58.Tw Fl 59.Tp Fl f 60Fold upper and lower case letters for sorting. 61.Tp Fl t 62Prepare the output for the phototypesetter; 63the default line length is 100 characters. 64.Tp Cx Fl w 65.Ws 66.Ar n 67.Cx 68Use the next argument, 69.Ar n , 70as the width of the output line. 71The default line length is 72 characters. 72.Tp Cx Fl g 73.Ws 74.Ar n 75.Cx 76Use the next argument, 77.Ar n , 78as the number of characters to allow for each gap 79among the four parts of the line as finally printed. 80The default gap is 3 characters. 81.Tp Cx Fl o 82.Ws 83.Ar only 84.Cx 85Use as keywords only the words given in the 86.Ar only 87file. 88.Tp Cx Fl i 89.Ws 90.Ar ignore 91.Cx 92Do not use as keywords any words given in the 93ignore 94file. 95If the 96.Fl i 97and 98.Fl o 99options are missing, use 100.Pa /usr/share/dict/eign 101as the 102ignore 103file. 104.Tp Cx Fl b 105.Ws 106.Ar break 107.Cx 108Use the characters in the 109break 110file to separate words. 111In any case, tab, newline, and space characters are always used as break characters. 112.Tp Fl r 113Take any leading nonblank characters of each input line to 114be a reference identifier (as to a page or chapter) 115separate from the text of the line. 116Attach that identifier as a 5th field on each output line. 117.Tp 118.Pp 119The index for this manual was generated using 120.Nm ptx . 121.Sh FILES 122.Dw /usr/share/dict.eign 123.Di L 124.Dp /usr/bin/sort 125.Dp /usr/share/dict/eign 126.Dp 127.Sh HISTORY 128.Nm Ptx 129appeared in Version 7 AT&T UNIX 130.Sh BUGS 131Line length counts do not account for overstriking or 132proportional spacing. 133