#! /bin/sh
# PostScript program wrapped up in a Bourne Shellscript.
# copyright 1987 by Peter Greenberg.

# This stuff can be used, copied modified, and incorporated into other works
# so long as this message and the copyright message are retained.

# comments/bug fixes to:
# Peter Greenberg
# Swarthmore College
# Swarthmore, PA 19081
# (215) 328-8610
# UUCP: ...!seismo!bpa!swatsun!greenber
# ARPA: [email protected]

spooler=lpr
spoolopts=

cat <<End-Of-Main-Stuff | $spooler $spoolopts
%!
% Just a little hack to show the name of each font printed in that font.
% Of course, non-alphabetic fonts will look strange. Will print the name
% of each font that PostScript knows about, one to a line.

% This program takes a while to run on an LW+.

/Font %fontname scale
{
       /scale exch def
       findfont
       scale scalefont
       setfont
} def

/Size 15 def

/Lineheight Size 3 add def

/Leftmargin 30 def

/Topmargin 770 def


/Showinfont % string fontname
{
       Leftmargin currentpoint exch pop Lineheight sub moveto
       Size Font
       show
} def

Leftmargin Topmargin moveto

FontDirectory {
       pop dup 256 string cvs exch Showinfont
} forall

showpage

End-Of-Main-Stuff

exit 0