PSIFY(1)

NAME
psify - pretty print C, CLU, SCHEME, Java, and ARGUS source files for POSTSCRIPT printers

SYNOPSIS
psify [options] [file] ...

DESCRIPTION
Psify is similar to pressify, a program that converted ASCII files to PRESS format to be printed on the Dover. However, psify converts files to POSTSCRIPT format for printing on a POSTSCRIPT printer. Psify will work with any ASCII file, but is meant for printing C, CLU, and ARGUS programs. It uses the file name extension to determine how to print a file. ".c" and ".h" are assumed to be C, ".clu" is CLU, ".arg" is ARGUS, ".scm" is SCHEME, ".java" and ".pj" are assumed to be Java, and anything else is printed as plain text. For C, CLU, SCHEME, Java, and ARGUS, comments and reserved words are printed in different fonts to make the listings easier to read. By default, comments are printed in italics and reserved words are printed in bold.

If no files are given on the command line, psify will read from standard input. Also, psify always produces output on standard output. Normally, the output should be piped to lpr in order to actually produce a printout.

Options are:

-fbfont
    sets the normal body font. Default is Courier10. The size may be specified with the font (all one word). If it is omitted, the default size will be used.

-fhfont
    sets font for page headers. Default is Times-BoldItalic12.

-frfont
    sets font for reserved words (for program source files). Default is Courier-Bold10.

-fcfont
    sets font for comments (for program source files). Default is Courier-Oblique10.

-fxfont
    sets font for reserved words in comments (for example, javadoc comments in program source files). Default is Courier-BoldOblique10.

-fafont
    sets font for body, reserved words, and comments to the font specified.

-sznumber
    if number is greater than zero, this option forces the body, comment, and reserved fonts to all be this size. Lets you just change the size of the fonts used without specifying each font individually.

-lmnumber
    sets left margin in points. Default is 72 (one inch).

-tmnumber
    sets top margin in points. Default is 36. Note that the page header is printed in the top margin, so that if it is made too small, the header will disappear.

-bmnumber
    sets bottom margin in points. Default is 36.

-2  rotates the paper 90 degrees and prints in two columns.

-d  attempts to tell the printer to print on both sides of the page. The printer may ignore the request.

-clu
    forces all files to be printed as if they were CLU source files.

-c  forces all files to be printed as if they were C source files.

-scheme
    forces all files to be printed as if they were SCHEME source files.

-java
    forces all files to be printed as if they were Java source files.

-arg
    forces all files to be printed as if they were ARGUS source files.

-text
    forces all files to be printed as plain text files.

-today
    forces use of today's date in the header (default is to use a file's last modification date).

-h[text]
    if text is null, no page headers are printed. Otherwise, the file name that is usually in the page header is replaced by text.

-   ends options. Allows a file whose name starts with '-' to be printed.

DIAGNOSTICS
Aborts if given an unknown option. Prints a message if it cannot open a file (the other files on the command line will still be printed).

AUTHOR
Andrew Heybey, atheybey@ptt.lcs.mit.edu

BUGS
None known.

NOTES
The input is parsed using a hairy lex file. Other languages could be implemented without too many problems, but I felt no pressing need to do so.

For CLU and ARGUS, the reserved words true, false, and nil, are not printed in bold because they are literals.