If printmon is used together with GhostScript, GS can process the jobs of the monitored PostScript printing queue and send the output to your real printer, such as a LaserJet or any other printer supported by GS that is not capable of interpreting PostScript directly.
This allows you to print transparently using PostScript from any application in your system without having to print to files and to call GhostScript manually.
Ideally, such a setup is installed on a LAN server which can then export the PostScript queue processed by GhostScript to any LAN clients. Then the clients don't have to worry (or even know) that there is no *real* PostScript printer on the net but a "dumb" one driven by GhostScript.
A sample use of printmon with GhostScript is demonstrated in gsmon.cmd:
@echo off rem how to use the printer device monitor with GS setlocal set gs_lib=c:/ghost/lib;c:/psfonts set gs_load=10 printmon lpt2 "gs -sDEVICE=ljet3 -sPAPERSIZE=a4 -sOUTPUTFILE=lpt1 -q -" endlocal
As you can see, the source code (printmon.c) is remarkably simple. However, it uses the 16-bit device monitor API (DosMon), that is not available in a 32-bit variant (similar to Kbd, Vio and Mou). But the API can be accessed with gcc using the interface definition in mon16.* for emx 0.8h and above. Printmon can also be compiled with MS C 6.00, in this case the DosMon API is available directly.
The program requires the EMX runtime DLL's, get the latest emxrt.zip which contains it.
This program is freeware. The author is not responsible in any way for any problem caused by it, even if the program is used correctly.
Kai Uwe Rommel
rommel@ars.muc.de
PRINTMON is available from Hobbes as printmon.zip.
For Unix, see The Linux Printing HOWTO for details of how to set up a Magicfilter.