This file is divided into two sections:

1) How to setup the print utility to work with QNX Windows
2) Details on the print utilities (pictps, picthp and pictpr)

==============================================================================
1)	The print support in QNX Windows has several levels. 
The highest level starts with the OLWM.  Menu items exist
in the window menus to allow the user to 'Print Window' or 
'Print Picture'.  This sends a message to OLWM to begin printing.  

	The user is then prompted to enter a destination filename 
or an output device.  If you decide you wish to print to a device
(ie: /dev/spool/pictps) then you must have the spooler program 
configured correctly.

	To configure your spooler the following lines can be
added to your lpsrvr.(node) file:

[printer.pictps]
	ci=pictps
	qn=printer

Please see the qnx4 Print Spooling chapter in the User's Guide
for more details on configuring spool devices.

	If you choose not to use a device and instead want to
save the print information to a temporary file then enter a
filename (ie: /tmp/dump).  Once this file has been created
then you can run the pictps program on it and either
redirect its output to a file or to a print device.  (ie:
pictps /tmp/dump > /tmp/dump.ps) If another temporary file
was used then all that remains is to spool the file for
printing. (ie: lp -P printer.ps /tmp/dump.ps)

===============================================================================
2)	The following is the detailed usage for the pictps utitlity.

PICTPS: 	PostScript printing support for QNX Windows

To install the PostScript driver, the file qw.prolog must
be located in /windows/config.  The utility 'pictps' resides
in /windows/bin.

Detailed usage:

pictps [options] file > output
pictps [options]

       Pictps with no filename will accept input from stdin and will
write to stdout.  Input can be either a .pict file or a .prt file.  The
latter can contain the definition of a picture, a window or even an
entire screen to be translated into PostScript.

Options:

-a msg				Annotate the printout with a message

					The text 'msg' will be printed underneath the printed
					area on the right-hand side.  This option is useful
					for adding place and time stamps or filenames to printouts.

-b bkgd				Force the background colour

					The -b option is valid when printing individual pictures
					or windows.  'bkgd' is a QNX Windows colour index.

-c filename			RGB mapping file

					This option can be used to specify a colour mapping file 
					to pictps.  It is explained in more detail below.

-e					Output in Encapsulated PostScript format

					-e directs pictps to output EPS conforming
					files for use with other applications.

-H					Attempt to print in Helvetica

					Pictps will attempt to replace the default mapping
					from QNX Windows fonts to Courier fonts by a mapping
					to Helvetica.  Because Helvetica is a proportionately
					spaced font, results are not always satisfactory.

-l filename			File to search for link pictures

					If a .pict file contains elements created using DrawLink,
					it is possible to specify one or multiple library pictures
					where the original elements can be found.  This option is
					not necessary when the PrintXxxx functions are used 
					because they automatically resolve linked objects.  

					It is preferable to have links resolved at file creation time
				 	because pictps does not have adequate information in a picture 
					file to distinguish between link elements linked to the same tag
					but different different pictures. (This would mean, for example,
					that all icons created with DrawLinks to their respective
					"Icon"'s would appear the same in the printout.)

					Also, pictps must be connected to QNX Windows to resolve links
					which means that either -n nid must be used or QNX Windows must
					be running locally.						

					*** NOTE ***
					As of July 12, 1993, the PrintXxxx functions do not resolve
					links in icon elements.  This means that a default icon
					picture should be specified if any icons with link elements
					are being printed, such as sedit or maildog.

-m					Write minimally conforming EPS

					Some older applications are confused by full EPS output.
					This option restricts output to the bare minimum needed
					to conform to the standard.

-n nid				Attempt to connect to QNX Windows by nid

					When used in conjunction with the -q option, -n allows
					the user to query a remote screen for configuration
					information.  (See -q)

-o					One to one mapping

					-o maps 1 tip in QNX Windows to 1 point in PostScript.

-p papersize		0: Letter 	1: Landscape letter 
       				2: Legal	3: Landscape Legal	

-q					Query Windows for palette, font and scaling information
					
					By default, the local Windows server is queried.
					The use of this option is explained in more detail below.

-s					Black window outline

					Windows are modelled 3d by default.

-v					Verbose mode (output on stderr)

Colour Control:

	Pictps determines colour information in the following order,
depending on the command line options and the type of file being
interpreted:              

	1)	Hard-coded defaults
	2)	Read from input file (.prt files only)
	3)	Query of Windows server (if -q is specified)
	4) 	Colour mapping file (if -c is specified)

	Note that this implies that a colour mapping file overrides the
result of a Windows query.  Also, if a .pict file is being printed
that contains more than 16 colours, either -q or -c must be specified
on the command line because pictps has no defaults for colours above
16.


RGB Mapping Files:
	
	Each line in the RGB mapping file should be one either of the
following formats:

	
QNX_Windows_colour_number RED GREEN BLUE (/1.0)
		or
QNX_Windows_colour_number Gray percentage (/1.0)
		or
A line can be of the same format as a screen rgb mapping file, such as
/windows/config/color.cfg.  

The following text could be used as a gray scale map file:

# R    G  B
--------------------Begin---------------
1 0.75 .3 0.3334
5 0.4
2 0.7 0.7 0.7
--------------------End-----------------

Mapping Fonts:

Most PostScript implementations come with only 2 non-proportional fonts,
making mapping from QNX Windows fonts to PostScript fonts quite simple.
This mapping information is extracted on demand from the file 
/windows/config/ps.fontmap.  If there is no entry in the file for a font
encountered in a picture, the default system font is assumed.  The format of
the configuration file is described as a comment in that file.

Pictpr and Picthp.

These two programs accept data which has been created by the
PrintArea function.

Once the data has be captured off the screen, it
can be processed for printing with either picthp or pictpr. 
The picthp program is used to prepare the data for HP
LaserJet printers, the pictpr program is used to prepare the
data for dot matrix printers. Both picthp and pictpr have
similar options:

Use: pictpr printfile [options] > output
Options: +debug
		 +mono output
		 +fast (mono only)
		 +120 dpi (default 240dpi)
		 -scaling (ie: 1to1)

Use: picthp printfile [options] > output
Options: +debug
		 +mono output
		 +150 dpi (default 300dpi)
		 -scaling (ie: 1to1)

+debug:		This was used when developing the program, it is not of interest
			to end users.
+mono:		Colors are mapped to either black or white, not the usual gray
			scale.  This increases resolution by a factor of 3.
+fast:		Only available in pictpr.  Prints the image in mono, low
			resolution, and without scaling.  It is the fastest print
			mode for pictpr.
+120|+150:	These are the low resolution print modes for either program.
-scaling:	This option disables the scaling feature.  On dot matrix printers
			this option should be used with the +120 option.

It is important to ensure that the data being sent to your
printer is  untouched.  

