Knowledgebase article Overlays and background images in Print Wizard
Print Wizard supports numerous types of overlays, or background images that are printing on the page with the print job.
A powerful and useful feature of Print Wizard is its ability to print forms as overlays. An overlay is any printing that is placed on every page of output, in combination with the text (or other content) that is coming from the main file.
The term “overlay” is actually a misnomer. It should be “underlay”, because it is generally drawn first on the page, with the variable text over it.
When overlays are printed as part of the output, it creates a way to print on plain paper what would otherwise require a preprinted form. This can be a significant cost savings. The classic illustration of an overlay is in printing invoices. You have a file of text that in the past has been printed on preprinted invoice forms. If you can create an electronic image of that invoice form (as described below), Print Wizard can print the invoice plus the text on each page. Another example would be a watermark; that is, an image or large text that prints lightly in the background of each page.
Historically, an overlay has consisted of one image, which was printed on every page of output. However, Print Wizard also supports multi-page overlays, in which the overlay images are cycled as text is printed.
Note also that Print Wizard can apply overlays to non-printed output, namely faxes and PDFs.
Finally, an overlay is always considered to be a full-page image. There is no mechanism for specifying the placement of text on the page at present. If you are in need of this, please contact us as it is under development.
An OVERLAY is always contained in a separate file. This file, like the main print file, can be on a local disk, a network drive, or an HTTP, HTTPS, or FTP server. You can specify that a particular overlay file should be used a) externally, such as in the command line for PRINTWIZ.EXE; b) in a print-initialization file; or c) in the PWML header of the main print file.
A special case of overlays is the PREVIEWOVERLAY. This is an overlay that is shown only in the Print Preview window. It is not actually printed. This can be useful as an image of the preprinted form (or label stock) that the data will be printed on. You can use the adjustment capabilities of the Print Preview window to make the data line up correctly on the overlay.
The way that Print Wizard handles an overlay file depends on its file extension. Make sure that’s right.
Following are descriptions of the various kinds of overlays Print Wizard can support.
Bitmap Overlays
A bitmap overlay is a simply a file that contains a picture that you want in the background. Some notes:
- Works on any non-generic printer
- Supports BMP, GIF, TIF, JPG, JPEG
- Image is stretched to the full size of the paper, including covering unprintable areas. If you are prescanning a form, scan it edge-to-edge so it will print at the same size.
- One-page overlay only.
Scanned Overlays
In this case, you scan something to use as an overlay at the start of the print job. You specify this by using the reserved filename “SCAN://”. Some notes:
- Works on any non-generic printer, fax, PDF.
- Supports any TWAIN-compliant scanner
- Image is stretched to the full size of the paper, including covering unprintable areas. Scan it edge-to-edge so it will print at the same size.
- For best results, scan at the same dot density as the printer.
- One-page overlay only.
EMF and WMF Overlays
Any EMF (Enhanced Meta File) or WMF (Windows Meta File) can be used as an overlay. These files can be created by many graphics programs.
- Works on any non-generic printer, fax, PDF.
- Image is stretched to the full size of the paper, including covering unprintable areas.
- File extension “EMF” or “WMF”.
- One-page overlay only.
SPL Overlays
An SPL (spool) file is even more enhanced than an Enhanced Meta File (EMF), because it can contain multiple pages. SPL files are created by capturing print output from other programs, as described elsewhere. Notes:
- Works on any non-generic printer, fax, PDF.
- Image is stretched to the full size of the paper, including covering unprintable areas.
- File extension “SPL”.
- Can be multi-page. Pages are cycled as data is printed.
PCL Overlays
As previously described, a PCL file can be used as an overlay. Described elsewhere is how to create a PCL file using a Windows printer driver. Notes:
- With TranslatePCL on, works on any non-generic printer, fax, PDF.
- With TranslatePCL off, requires a PCL-5 printer and driver. This is more efficient.
- File extension “PCL”.
- Can be multi-page. Pages are cycled as data is printed.
PWML Overlays
You can use a file containing PWML markup as an overlay. This would be appropriate if you wanted to describe the overlay using PWML tabs, such as <LINE> and <HR>. The entire overlay file is processed first, and saved as one or more pages in memory (as EMFs). These are then added to the data from the main file. There is no interaction between the tags in the overlay and the tags in the main file. Notes:
- Works on any non-generic printer, fax, PDF.
- File extension “PWML”.
- Can be multi-page. Pages are cycled as data is printed.
Comparison of Methods
The primary tradeoffs between methods are file size, speed, and portability. A full-page bitmap is a large file, and it must be sent to the printer for each page of output. It is inherently inefficient.
A WMF, EMF, or SPL file can be small, depending on how it is produced. It must be sent to the printer for each page. Also, although these metafiles are designed to be portable between versions of Windows and types of printers, there could be problems. Fonts specified in a metafile might not be present on a different PC.
PCL files can be quite small and efficient. Later drivers (LaserJet 5 as compared to LaserJet 3, for instance), tend to be smaller. They are very portable. PWML files are small, efficient, and extremely portable. However, they must be created by hand.
More Tradeoffs
Printing and working with overlays may be quite slow at times, and even may not work at others. There are many dependencies on how all this works. Here are some notes that may help you decide how best to approach overlays:
Not everything accepts a PCL overlay
Of course, the first issue is that the printer must be able to print PCL. But even then, it may not be that simple.
If you use a PCL file as an overlay (without "translatepcl" being turned on), Print Wizard will attempt to load the print file as a macro for that printer. This means the next requirement is that the printer must accept macros. Just because the printer can print your PCL file, does not necessarily mean that the printer can take the raw PCL file as an overlay. An example of this is a simple PCL file used as an overlay on an HP 4500 versus on an HP PSC 2355. The first accepts macros, the second does not. You can still print the overlay on the second, but you must turn on "translatepcl" first (to do so, include the "translatepcl" option in the setup of a print profile, or include the command line switch \translatepcl when running the Print Wizard engine).
Speed is not necessarily determined by the printer
PCL files may include bitmaps, fonts, text, and other printer controls. They can be quite complex (a mixture of small bitmaps, fonts, bitmap fonts, vector drawing commands, and printer setup commands, or quite simple (just a series of bitmaps, including for the fonts). However, sometimes the simpler the file, the slower it is. The reason being that there are lots of printer and printer driver dependencies that come into play:
- what printer driver and driver version created the PCL file
- the efficiency of the raster engine in the printer
- memory in the printer
- the efficiency of the driver to generate the print job
- the fonts used and whether the printer does font substitution for resident fonts
- the available memory and swap space on the PC
- the PC CPU speed and how well the driver utilizes the processor
- whether you are running a networked printer and whether the driver resides locally
- and more...
PCL 5 versus PCL 6
It is important to note that a PCL 5 printer driver most likely will have problems with a file generated with a PCL 6 printer driver on another system. However, most all PCL 6 printers will support PCL 5 printer drivers. So even if the printer came with a PCL 6 printer driver for Windows, you can usually find a compatible PCL 5 driver for your printer on the web.
Print Wizard with "translatepcl" on cannot handle overlays created with a PCL 6 printer driver. In this case, you would have to have a printer capable of handling the PCL 6 overlay directly (a printer that supports macros).
The Future
Print Wizard and overlays are greatly expanding areas at Rasmussen Software as demand has been high. Print Wizard can perform basic overlays including applying them as a printer's macro, combining before getting to the printer, and combining and sequencing multiple overlays.
In the very near future, look for overlay support in BANG commands, sequencing of multiple page overlays, printing overlays even where there is no data, and more. We continue to develop in this area.
If you have any specific needs, please contact us as we are interested in what the needs are out there in the world of printing.
|
|