Operating System - HP-UX
1755461 Members
3354 Online
108833 Solutions
New Discussion юеВ

Re: PDF printing capability on hp-ux

 
Chirag Parekh
Advisor

PDF printing capability on hp-ux

Hi,

We have a lot of HP LJ printers that are on the network and I wanted to know if there are any drivers or any method of printing the lp requests to a PDF format instead to the printer.
4 REPLIES 4
A. Clay Stephenson
Acclaimed Contributor

Re: PDF printing capability on hp-ux

Go to this website and enter "PDF" as a search string and see if a few ideas don't bump into each other.

http://hpux.cs.utah.edu/
If it ain't broke, I can fix that.
whiteknight
Honored Contributor

Re: PDF printing capability on hp-ux

Chiraq Parekh,

I cannot find any tools in hpux to print the data into PDF format instead of print.

http://hpux.connect.org.uk/hppd/cgi-bin/search?package=on&description=on&term=pdf



WK
Problem never ends, you must know how to fix it
Matti_Kurkela
Honored Contributor

Re: PDF printing capability on hp-ux

I haven't actually done this, but I understand you would have to write a "model script" for PDF output pseudo-printer.

To understand how a model script works, it's easiest to examine a "local" print queue first. The printing subsystem invokes the model script like this:

model_script < printable_data > /dev/printer_device

A model script can change the data any way it wishes. Normally this is used for character conversions and the like, but it can be used for other things too.

A remote printer is just like a local printer, but the "tty device" is replaced by /dev/null. The model script for a remote printer contains a command /usr/sbin/rlp which is used to send the print request to the remote lp server. A Jetdirect printer's model script is constructed in a similar fashion, but it uses a different tool for sending the data to the actual printer.

You could build your own model script for PDF output. PostScript data could be converted to PDF using GhostScript with the required PDF output options. Other input formats might need some more processing: ASCII text might have to pipe through ASCII-to-PostScript converter (pslp) before passing it to GhostScript, for example.

Other things to think about: how do you want the output filename to be determined? Remember that the model script is started by lpsched, so it's going to run as user "lp" and thus it's going to have very limited permissions.

MK
MK
A. Clay Stephenson
Acclaimed Contributor

Re: PDF printing capability on hp-ux

If you are willing to spend money then one product that works very well and can produce amazing output is UnForm. It's easy to integrate into the lp subsystem. It works by taking plain text input and looking for patterns (e.g. My Report on line 3, column 38; mm/dd/yyyy on line 4, column 70) and when it an input stream matching all those conditions, it applies a set of "rules" to transform the input into PDF, PCL, HTML, ... .

http://www.unform.com/sdsi.cgi?p=unform7

You can download a trial version.

If it ain't broke, I can fix that.