Return to the Article Index
Return to the Main CD Index

Graphic Interpretation - Laser Magic
by Bruce Thomas

One of the greatest 'features' of GEOS is the open nature of the system; by this I mean all of the programming information available to users. While every user is not a programmer, every user has benefitted from the many great programs that have been created by users who are programmers. We have also been very lucky that a lot of smart and adventurous people have been GEOS users.

Among these pioneers of GEOS, a number stand out for their contributions to using GEOS with a Laser Printer. These include Randy Winchester (whose series of articles in GeoWorld helped me start using a Laser for output in the fall of 1988), Dale Sidebottom (who has been a dedicated GEOS Laser user for many years; he has also recently made some HUGE new laser developments), Skip Goetzinger (whose Laser Direct service provided a means for GEOS users to have inexpensive access to Laser output and also published numerous Laser Printer Publishing kits to help do things right), David Ferguson of Quincy Softworks and Dweezil fame (who wrote a comprehensive GeoPublish Laser Printing Compendium), Jeanine Cutler (who bought an HP Laser and wrote a couple of articles for GeoWorld) and Jim Collette (a brilliant young programmer who wrote many fine GEOS programs).

We are going to explore the use of one of Jim's programs. 'PS Processor' is available from Creative Micro Designs, Inc. on the Collette Utilities disk. This terrific program allows easy manipulation of PostScript files and enables a variety of print options. The program uses a simple script file (written in geoWrite) that tells it where to place each page of a geoPublish document for custom Laser printing.

Compatibility

The 'PS Processor' dox, and Jeanine Cutler's useful examples which come with the program, incorrectly state compatibility problems. 'PS Processor' operates properly no matter which version of geoPublish or geoPubLaser you have. You must, however, have the properly matched versions of these programs as that is where the incompatibility occurs.

If your geoPublish is dated 10/8/87 you must use geoPubLaser dated 3/10/88. For the two-disk geoPublish dated 10/4/88 you must use geoPubLaser dated 10/25/86. Using mismatched versions of these programs will result in improperly formatted output.

Once you have the correct geoPubLaser, a copy of it must be patched with 'PS.Patch(disk)'. This patch program is also on the Utilities disk and enables 'PubLaser to write the PostScript file to disk so 'PS Processor' can do its magic.

Which Page do You Want

In this article I will talk about three types of pages. Logical Page refers to a page as viewed in geoPublish and as written to disk with a patched geoPubLaser. Virtual Page refers to the page that is assembled in the memory of the laser printer prior to printing. Physical Page refers to the page that comes out of the laser with your document on it.

While normal geoPublish output prints one logical page to each physical page, 'PS Processor' takes advantage of the PostScript language to allow multiple logical pages to appear on each physical page.

'PS Processor' also makes it possible to print in landscape mode. Normally, output goes to an 8.5" * 11" letter size physical page with the 8.5" side along the top - this is called portrait mode. Landscape mode prints to the same 8.5" * 11" physical page but the 11" side is along the top (virtually rotating the output 90 degrees). In addition, output can now be formatted to fill an 8.5" * 14" legal size physical page in both portrait and landscape modes.

To make these printing options all possible, 'PS Processor' makes use of a virtual page in the Laser Printer. Depending on the mode selected, the default virtual page allows different sections of the logical page to appear in different locations on the physical page. Luckily, we can move the location of the logical page, or we can move the virtual page origin, by including coordinate offset values in our script file. Are you thoroughly confused yet?

The Coordinate Grid

As mentioned, the chosen mode determines the location the logical page will print to. This is best understood by placing X and Y coordinates on a graph Figure 1 shows the default origins and the relationship of the logical page orientation to each physical page mode.

In portrait mode the default origin is located in the lower left corner of the page. This allows the entire logical page to appear on the letter or legal size physical page.

In landscape mode the default origin places the top 8.5" of the logical page on the physical page with 2.5" of space along the right edge (this is true on both letter or legal size paper). If you wish to place your logical page at the left landscape edge of a legal size physical page you must use an offset of -240 to shift the logical page 3" left.

Where did the -240 come from? The coordinate system is based on the dot resolution of GEOS, not the Laser. The horizontal resolution is 80 dots per inch (dpi) and the vertical resolution is 72 dpi. Three inches multiplied by 80 dpi equals 240 dots for an offset. The offset values are in relationship to the origin with positive values moving the logical page right (X) or up (Y) and negative values moving the logical page left (-X) or down (-Y).

The Project

I recently returned to school to drastically change my career path and wanted some cards I could hand out to people I met in my future field of work. Rather than go to a local business, I put GEOS to work and made my own.

To do my business cards I bought a package of perforated sheets with 10 cards on each sheet. These cards are standard size (3.5" * 2") and geoPublish can easily do the layout to match the cards. With 'PS Processor' we only have to create one card in the geoPublish document and then add it to the virtual page multiple times via the commands in our script file.

Putting it all into Practice

To better understand the whole 'PS Processor' process we will look at my business cards. More understanding can be realized by printing Jeanine's examples.

Since 'PS Processor' allows us to place multiple logical pages, or copies of the same logical page, onto each virtual page we only need to create one business card in geoPublish. The card sheets I bought had 1/2" borders on the top and bottom and 3/4" borders on each side. The rulers in geoPublish made it easy to create my card in the top left position by setting horizontal guidelines at 1/2" and 2 1/2" and vertical guidelines at 3/4" and 4 1/4" (Figure 2).

I used a geoWrite file for my personal information. After importing this file (which was laid out entirely with 'LW' fonts for best quality laser output) I added the graphics and was ready to print. If you are going to take your printout to a copy shop to be copied onto card stock use the same layout but add crop lines in the corners to mark where to cut the cards (Figure 2).

And, Action!

Just like a Hollywood movie, 'PS Processor' needs a script to make things happen. Scripts are a collection of commands contained in a geoWrite file that instruct 'PS Processor' what to do with the logical pages in the disk file created by the patched geoPubLaser.

To print the business card in ten locations on the physical page the script must use a series of 'include' commands with offset values. Here is the script I used:

parallel
numcopies 10
include 1 0 0
include 1 0 -144
include 1 0 -288
include 1 0 -432
include 1 0 -576
include 1 280 0
include 1 280 -144
include 1 280 -288
include 1 280 -432
include 1 280 -576
print last

The first line tells 'PS Processor' that a laser is connected to the 64 via a geoCable parallel connection. The second line sets the number of physical pages I want to print. By printing 10 pages I will get 100 cards. The third line adds logical page 1 to the laser's virtual page in the default location. The next four lines add logical page 1 to the virtual page at 2 inch intervals down the page (2" * 72 dpi = 144).

Since our cards are 3.5" wide we must shift the logical page 3.5" to the right. The next line (include 1 280 0) adds logical page 1 to the top of the virtual page but shifted right 3.5" (3.5 * 80 dpi = 280). The next four lines add the logical page to the right side of the virtual page at the same 2" intervals.

Finally, the 'print' command is sent to the laser indicating the virtual page is complete and ready to be output on a physical page. If more virtual pages were to be created another series of 'include' commands would start on the next line. Since we are done, we add the 'last' parameter to our 'print' command to reset the laser for another print job. That is the end of our script and 100 business cards will pop out of the laser.

Other 'PS Processor' commands allow the use of serial interfaces or outputting a file to disk, enabling landscape mode and changing the virtual page origin.

A Limitation

One thing that the 'PS Processor' can't make up for is the physical print area of various lasers. When I first printed off Jeanine's examples I did so on an Apple Laserwriter. This laser has a small print area when using legal size paper (6 3/4" * 13" compared to 8" * 13 1/2" on a Canon laser). I didn't realize this at first and thought there was a problem as the text was cut off around the edges. Knowing the print area of the laser that will be used for output will allow you to get the most use out of this fantastic GEOS program and soon you too will be performing laser magic not otherwise possible.