Section 2 : Client Applications

Q202: How do I create a fax cover page template?

? Got something to say about this answer? Hit the question mark to invoke the mailer and send your comments to the HylaFAQ maintainers.

How do I create a fax cover page template?

I'd like to create a new cover template page as I would prefer for our faxes to *not* go out with the Silicon Graphics logo. :)

Does anyone have experience doing this? Can someone point me toward the proper instructions? I've read the faxcover man page, which tells me how to use an alternative template, but I can't figure out how to create one.

Look on in the directory ~ftp/pub/sgi/fax/contrib/covers. This contains (among other things) a compressed and tarred file called make_faxcover.tar.Z It contains instructions as well as a script for converting a "tgif" eps file to a fax cover template. It was put together by Thomas Erskine.

(From Randy Davis) Here's how I did mine, and it works great. But, please note, I do *not* know postscript, I just figured out a good deal of it by trial and error and playing with modifying postscript source files.

Here's what you do:

  1. create a postscript file that contains your customized cover sheet that looks exactly as you like it, WITH sample text in each of the fields that you want the package to replace with the real text in actual use.

    I used FrameMaker to make ours, complete with company logo, and had FrameMaker output a postscript file. I suppose you could even use troff and use a troff-to-postscript converter if you like. The key part is to get a postscript file that looks as you like, and has sample text in each of the fields to be filled in by the program, each sample text of which is unique to each field so you can find each one buried in the postscript later on.

  2. Make a copy of this postscript file (just to be safe :-), and start modifying the copy this way:
    Modify the prologue (the first part of the postscript file prior to the actual pages) to add the following macros - I added them immediately after the first block comments at the top of the file (comments are denoted by a % at the beginning of the line). --------------------------------------------------------------------------- 1 setlinejoin /nullstring () def /IS { dup where { pop load dup nullstring ne {S} {pop} ifelse } {pop} ifelse } bind def /M { moveto } bind def /S { show } bind def --------------------------------------------------------------------------- You will have to see if the /M, /S, or /IS macros are redefined later on in the prologue, and if they are, you may have to make some decisions and do some work outside of the scope of this short instruction sheet. As I recall, the postscript file output by the version of FrameMaker *did* redefine one of them, yet I could not find it used anywhere in the rest of the document, so I just removed it with no ill effects. In any event, it is a good idea to have a postscript printer or working version of ghostscript handy so you can check your work after each modification to make sure the file still works (and backtrack if it breaks).
    Find your sample text strings in the postscript file (they will be enclosed in paranthesis) and change them to use the IS macro and M macros:

    This is the hard-to-explain part. Let me preface it with a quick intro into postscript text drawing. Each text string is enclosed in parenthesis, and either in front or after the text string on the same line is a macro and a set of coordinates detailing where to "draw" the text on the page. In addition, some packages, like FrameMaker, will sometimes break a string into two or more separate strings in the postscript document, for no reason that I can find. For instance, the phrase "Now is the time for all good men to come to the..." might all be on one line, not broken, in whatever utility you use to generate the postscript, etc, but your output postscript file may "draw" it in three sections, and even out of order, e.g.:

    (e for all good men to co) 120 523.33 T (Now is the tim) 72 523.33 T (me to the...) 173.5 523.33 T But, note that you can combine this into one string by just using the coordinates for the string that began the line (look for the smallest "x" coordinate, which is the first of the two coordinates), e.g.: (Now is the time for all good men to come to the...) 72 523.33 T And you should be unable to tell the difference on the output page.

    OK, so you need to find the sample text you put in to mark the location of the fields. This is best explained by example. For instance, in my template page straight from FrameMaker after I combined any broken strings, I have the following lines (which happen to be in order):

    (Please deliver to:) 72 523.33 T (Name:) 206.71 505.33 T (to-name) 270 505.33 T (Company:) 180.04 487.33 T (to-company) 270 487.33 T (Recipient\325s Extension:) 99.35 469.33 T (to-voice-number) 270 469.33 T (FAX Number:) 154.15 451.33 T (to-fax-number) 270 451.33 T (In each of these cases, it turns out that FrameMaker put the text strings preceding the coordinates, ending the line with "T", which turns out to be a macro which is defined in the prologue with a line or group of lines begining with "/T {" and which expects this line ordering.)

    If you will notice in my sample postscript exerpt above, you can identify the sample strings I put in to determine the exact coordinates of where I wanted the fields to be. Those sample strings are "to-name" (on the third line), "to-company" (on the fifth line), etc...

    Now, what you want to do is to convert each sample text line to the format expected by the faxcover EPSI wrapper. This involves changing, in my case, the format of:

    (text) T to the new format of: M / IS All you really need is the x/y coordinates and to know which parameter should go at these coordinates. Note that you only have to change JUST the lines that you want the program to fill the text in for - you don't have to change any other text lines, and should probably leave them alone. The s are defined on the faxcover man page. In my case, the modified exerpt becomes: (Please deliver to:) 72 523.33 T (Name:) 206.71 505.33 T 270 505.33 M /to IS (Company:) 180.04 487.33 T 270 487.33 M /to-company IS (Recipient\325s Extension:) 99.35 469.33 T 270 469.33 M /to-voice-number IS (FAX Number:) 154.15 451.33 T 270 451.33 M /to-fax-number IS
Thats basically all there is to it, or was to it for me. Hope this helps - feel free to ask me more if I missed something. Note that I only installed the package about four weeks ago, yet it all works fine, including the cover sheet. :-)

Date: Fri, 23 Feb 96 13:12 EST
From: David Gilbert < >

I submitted the following to the FAQ maintainer. In short, with Frame4.0, the instructions were enough to get me started, but were not the whole answer. So... the FAQ needs updating... but I'm prefixing my question with a helpful hints in hopes of encouraging someone to be similarly helpful.

From the instructions in the FAQ, I was not able to modify the postscript output of either Word or Corel (which are what the current fax cover pages at our company are done with). I finally caved in and created a duplicate of our cover page with Frame. After much tearing out-of-hair, I figured out that the line inserted by faxcover that is '100 dict begin' is too small for the frame output. Changing it to 200 dict begin makes it work.

I did this with emacs on the binary (since I havn't been able to get hylafax to compile on our SGI with either gcc 2-7-2 or the SGI provided CC). I also had to modify the windows client since it seems to do it's own cover sheet and also puts in the '100 dict begin'

With that modification, Framemaker 4.0 cover sheets can be made to print. However, the /M /S AND /IS macros are all defined and used by the Framemaker postscript. I fixed them by changing them to /MY /MS and /MIS (no particular reason). Note that /S is used by /MIS (in the {}'s) and must be changed there.

Date: Mon, 16 Dec 1996 15:22:52 +0100
From: Rainer Krienke <>
Subject: Announcment: new version of latex-cover

I uploaded a new version (1.03) of latex-cover to

This version contains a small bug-fix over the previous one. People who have no 
trouble running 1.02 need not get this version. The bug was in the template file 
lcover.tex . This file contained a command \today that should have been 
\todaysdate instead. Thats all!

For people who do not know about latex-cover:

latex-cover.sty offers a way to create custom coverpage templates for use
with the faxcover application from the hylafax distribution.

The advantage of latex-cover.sty for creating a coverpage template 
compared with
the possibility of changing the original template file is
that latex-cover.sty allows the design of the coverpage to be made in
latex(2e). On the other hand the file contains pure 
postscript making it rather difficult for a user to design a new
coverpage template.  
Using latex-cover.sty in conjunction with latex and dvips 
the user can now write a plain latex file and insert commands defined in
latex-cover.sty at those places where he wants to insert parameters
actually filled in by faxcover when a fax is beeing send.
The latex source can be comiled by latex and converted to the Postscript
template file via dvips. Thats all!

Rainer Krienke                
Universitaet Koblenz,

Date: Thu, 14 Nov 1996 11:17:48 -0600
From: Afan Ottenheimer < >
Subject: Cover letter template

I didn't see an easy template for creating a fax cover sheet and 
trying to program in postscript really didn't appeal to me.
So, I created a tgif template file (faxcover-template.obj)
which makes creating a cover page easy.

To create a cover page.
0) Get the make_faxcover script
1) Get tgif (I used 3.0 patchlevel 10)
2) Download the tgif template obj file 
  (submitted to:
3) "Open" the above file in tgif and replace our logos with your own
   or move stuff around. It is important that each text variable 
   field be unique.
4) Print to file as eps. It will automatically be named faxcover-template.eps
5) #make_faxcover faxcover-template.eps > 
     (or to whatever the FAXCOVER variable is set)
6) Replace your old cover-sheet template with the one you created in step 5

My thanks to the creators of HylaFAX, tgif, and make_faxcover who
made this possible.

Afan Ottenheimer

Date: Fri, 11 Oct 1996 11:20:48 +1300 (NZDT)
From: Jonathan Chen <>
Subject: Re: Making Cover Pages

On Tue, 8 Oct 1996, Eric Poole wrote:

> Well, I've looked throughout all the documentation I can find including the
> man pages and the online web-based docs, and I can't find it anywhere ...

Hmm. I used to remember a FAQ entry somewhere detailing just how do this..

> How do I generate cover pages, i.e. how do I make one that replaces the
> default one with the Silicon Graphics logo?

If you just want to remove the logo, you'll have to change the
faxcover postscript file. It's located in /usr/local/lib/fax/
Before making any changes, I'd make a copy of it first. You don't really
have to know Postscript to make these changes (I don't), but if you've
done any programming you can make reasonable guesses.

Look for "drawlogo". There'll be 2 instances of it. One is the function
definition, the other the invocation. You can remove the function:
    /drawlogo {
    } def

and the invocation


If you want to put in your Company name, look in the function /drawtext
and make an educated guess.. (It ain't too hard)

> I've managed to get as far as to generate a postscript file and use it as a
> cover sheet, but if I do that it won't insert the standard cover sheet info
> such as To:, Fax Number:, Company:, From:, # Pages:, etc.

If you look further down the default faxcover file, you'll see entry points
for putting in external info. These are:

If you've made your own cover page, you'll have to edit the resultant
Postscript file and put these entry points in. My guess is that you'll
have to put in something of the form:

    nnn mmm M /to-fax-number IS

where "nnn" and "mmm" are movement parameters.
Jonathan Chen                          e-mail :

 Back to FAQ Index FAQ Index  Next question in List Q203: How to do broadcasting faxes? Last updated $Date: 2002/03/08 05:42:44 $.