NAME
	lpr.prg - off line print


SYNOPSIS
	lpr.prg [-cdfglnopvt] [-Pprinter] [-h] [-m] [-#copies] [-iIndent] [-wWidth] [-Ttitle] [file ...]


DECRIPTION

Lpr uses a local or remote spooling daemon to print the named files. If no
file names appear the standard input is assumed.

The following single letter options are used to notify the printer spooler
that the files are not standard text files. The spooling daemon will use
the appropriate filters to print the data accordingly. The formatting
options are mutually exclusive:

-c	Cifplot
-d	TeX DVI
-f	FORTRAN carriage control
-g	Plot
-l	Raw. This is the default!
-n	Ditroff
-o	Postscript
-p	Postscript
-v	Formatted ISO 8859 Latin1
-t	Troff.

These options allow to modify output formatting:

-i	Decimals to specify indentation

-w	Decimals to specify page width in characters.

These options apply to the handling of the print job:

-P	Force output to a specific printer. Otherwise the printer 
	defaults to  lp

-m	Send mail upon completion; this is not supported by this version

-T	Title for the job

-h	Suppress banner

-#	Decimals to specify number of copies.


ENVIRONMENT

Lpr.prg does not use any environment variables.


FILES

Lpr.prg accesses variables that are defined in the file default.cfg in the 
STinG directory. Note that STinG reads this file to memory during STinG
startup (auto folder processing). Hence changes to default.cfg take only
effect when rebooting.

Lpr.prg needs the following variables:

HOSTNAME	Name of this, local computer on the network.
		E.g. thomas1.aaa.de
		Note that the host portion of HOSTNAME (thomas1 in the 
		example) is checked by some remote host OS (e.g. Linux) 
		against the file etc/hosts.lpd for authorisation.
		
USERNAME	Your user name. Usually you need an *account* under this 
		name on the remote host to be authorized to print.

lpr.prg supports up to 26 printers. For each printer you want to reach,
substitute a letter A to Z for the small x you find in the variable names
below. The printer name you supply with option -Pprinter indexes in this 
"array" of LPx_xy variables described below.

Per (remote) printer lpr.prg needs the following variables:

LPx_QN          Queue Name. Name of the printer. This may be any string you
                like. You will want however to have LPA_QN = lp in
                default.cfg as lp is the default printer when option -P is
                not present.

LPx_RP          Remote Printer. Optional. Name of the remote printer. If
                LPx_RP is omitted, LPx_QN is also used as the name of the
                remote printer and this must in any case be known at the
                remote host to be able to print.

LPx_RM		Remote Machine. This is the network name of the remote 
		host. E.g. thomas2.aaa.de or a dotted quad like 
		192.168.47.11 . This must fit your entries in route.tab or 
		the resolver.

LPx_SD		Spool Directory. This shall point to a writable directory
		for temporary files. This version of lpr uses this directory
		only if input comes from stdin.


SEE ALSO

lp-man.txt, lpd-man.txt


HISTORY

The lpr command appeared in 3BSD. Most of the formatting options are 
historical and their meaning may vary according to the remote spool daemon 
configuration. Lpr and related commands provide still the standard printing  
mechanisms on Un*x like systems and often come together with TCP/IP 
implementations for other operating systems.
Options and default.cfg variables deliberately resemble the Un*x options 
and entries in the printcap file.


DIAGNOSTICS

Lpr.prg fully conforms to RFC1179.

In contrast to other implementations this lpr tries to transfer directly to
the remote spooling daemon. A locally running daemon is not necessary.

Formatting option -l (raw, binary ) is default, whereas it is -p
(postscript) in many other implementations.

The command line is limited to 127 characters in length. This may be
changed in a future version.

In contrast to other lpr implementations this one does handle binary files, 
also for standard input.

Although this program is GEM executable, it reads from stdin when no file 
names are supplied. Thus it can be used from command files and read from 
pipes.
If you accidentally double click, it would sit and patiently wait until you
hit cntrl-z on the console.

Usage from GEM desktops that do not support drag and drop is almost
impossible as you needed to attach each extension from all files you would
like to print to lpr.

This lpr can not do any processing (filtering) to its input. Formatting
options are just forwarded to the spooling daemon (lpd). Hence files to be
printed must be in suitable format for the remote printer.
Exception: the remote printer daemon (lpd) supports filtering (most Un*x
ones do)

