🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: bit.listserv.script-l
Article #326

Re: Problem about printing Lucida Math Symbol

#326
From: Philip H. Smith III, 703 506-050...
Date: Tue, 21 Mar 1995 20:28
192 lines
7350 bytes
On 03/21/95 14:24:47 -0500, Giorgio Marinangeli said:
>I have a problem about printing mathematical symbols with a
>Postscript laser printer.

You do indeed need to download the font.  It'll have filetype EDFBGxxx,
I expect, and is binary.  Then you need to prepend a line like this:

serverdict begin 0 exitserver

(assuming 0 is your PostScript server password) and COPY (*not* PRINT,
in my experience) it to the printer.  Then if you send the PostScript
job which I'll hopefully remember to append to this, you'll print a list
of the fonts, which should now show the one you downloaded.  (Note that
the font name will print in the font itself unless you change a line
early in the program -- see the comments -- and this may make it hard to
read the font name.  I'd send the job once before downloading and once
after, to be surer.)

Yes, this is all gobbeldygook and magic.

Oh, and if you download it more than once, it'll eat storage in the
printer -- you'll want to bounce the printer in between.

Feel free to email me for more details; also see December 1994
_Enterprise Systems Journal_ for an article (by me) about this.

...phsiii
----------------------------------------------------------------------
%! PS-Adobe-2.0

% This file is a modified version of PSSTAT.PS as found in Ross Smith's
% book 'Learning PostScript: A Visual Approach'.

1 /native exch def  % 1 = print fonts in their native typeface
% Change above to 0, for faster printing of fonts in single typeface

/font {findfont exch scalefont setfont} bind def
/box {1 index 0 rlineto 0 exch rlineto neg 0 rlineto closepath} bind def

/tab {
     currentpoint exch pop
     leftmargin 120 add exch
     moveto
} def

/nl {
    currentpoint leftmargin exch ptsize sub moveto
    currentpoint exch pop bottommargin le {
        /leftmargin leftmargin columnwidth add def
        leftmargin topmargin moveto
    } if
} def
/sshow {s cvs show} def
/tshow {tab sshow nl} def

/printerinfo {
    statusdict begin
        /printname where
        {pop (printer name) show 64 string printername tshow} if
        /product where {pop (product) show product tshow} if
        /version where {pop (version) show version tshow} if
        /revision where {pop (revision) show revision tshow} if
        /dojamrecovery where {pop (jam recovery) show dojamrecovery tshow} if
        /defaultduplexmode where {pop (default duplex mode) show duplexmode
tshow} if
        /duplexmode where {pop (duplex mode) show duplexmode tshow} if
        /doprinterrors where {pop (print PS errors) show doprinterrors tshow} if
        /doautocontinue where {pop (auto continue) show doautocontinue tshow} if
        /doret where {pop (doret) show doret tshow} if
        /tumble where {pop (tumble) show tumble tshow} if
        /defaulttumble where {pop (default tumble) show defaulttumble tshow} if
        /firstside where {pop (firstside) show firstside tshow} if
        /defaultpapertray where {pop (default papertray) show defaultpapertray
tshow} if
        /papertray where {pop (papertray) show papertray tshow} if
        /defaulttrayswitch where {pop (default trayswitch) show
defaulttrayswitch tshow} if
        /trayswitch where {pop (trayswitch) show trayswitch tshow} if
        /defaultoutputtray where {pop (default outputtray) show
defaultoutputtray tshow} if
        /outputtray where {pop (outputtray) show outputtray tshow} if
        nl

   end % statusdict
} def
/otherinfo {
    72 72 matrix defaultmatrix   % Calculate the number of device
    dtransform                   % Pixels for one inch in the x dimension
    /hres exch round abs cvi def % Stack: abs(y') x'
    /vres exch round abs cvi def % Stack: abs(x') abs(y')
    /eres vres hres mul sqrt cvi def
    vres hres eq {
         (Device resolution:) show tab hres sshow ( dpi) show nl
         }{
         (horizontal resoultion:) show tab hres sshow ( dpi) show nl
         (vertical resolution:) show tab vres sshow ( dpi) show nl
         (effective resolution:) show tab eres sshow ( dpi) show nl
    } ifelse
    nl

    /height y2 y1 sub def   % height = top margin - bottom margin
    /width x2 x1 sub def% width = right margin - left margin
    (left margin) show tab x1 sshow (, ) show
    x1 72 div sshow (in.) show nl
    (bottom margin) show tab y1 sshow (, ) show
    y1 72 div sshow (in.) show nl
    (imageable height) show tab height sshow (, ) show
    height 72 div sshow (in.) show nl
    (imageable width) show tab width sshow (, ) show
    width 72 div sshow (in.) show nl
    nl
} def % otherinfo

/memoryinfo {
   vmstatus           % savelevels used max
   dup                % savelevels used max max
   3 -1 roll          % savelevels max max used
   sub sshow ( of ) show
   sshow ( bytes remaining) show nl nl
   pop
} def
/bubblesort {
    /v exch def
    /n v length 1 sub def

    n -1 1 {
         /i exch def
         0 1 i 1 sub {
             /j exch def
             /t1 v j get def
             /t2 v j 1 add get def
             t1 t2 gt
             {
                 v j t2 put
                 v j 1 add t1 put
             } if
         }for
    }for
} def % bubblesort

/fontinfo {
    /FontArray [ FontDirectory {pop 128 string cvs} forall] def
    FontArray bubblesort
    FontArray length sshow ( fonts available:) show nl
    nl
    FontArray {
       /fontname exch def
       gsave
           % Comment out next line to disable native mode
           native 0 ne {
               ptsize fontname cvn font
           } if
           fontname show
           FontDirectory fontname cvn get
           /FontType get 1 eq { (*) show } if
       grestore
       nl
   } forall
   nl
   (* = Type 1 font, may have been downloaded) show nl
   nl
} def % fontinfo
gsave
     initgraphics     % Reinstate default clipping path
     clippath         % Set current path to clipping path
     pathbbox         % Place path bounding box on the stack
     /y2 exch def
     /x2 exch def
     /y1 exch def
     /x1 exch def
grestore

/ptsize 10 def
/s 128 string def
/columnwidth 220 def
/topmargin y2 ptsize sub 5 sub def
/leftmargin x1 5 add def
/bottommargin y1 10 add def

ptsize /Times-Roman font

newpath  % draw a box around the defined clipping region
x1 y1 moveto
x2 y2 box
stroke

leftmargin topmargin moveto
printerinfo
otherinfo
memoryinfo
fontinfo
showpage
Technical Details
Message-ID: <PHILS.950321152859@relay.relay.com>
Path: arc1-ca.pugleaf.net!nntp.gmd.de!news.rwth-aachen.de!news.rhrz.uni-bonn.de!RRZ.Uni-Koeln.DE!uni-duisburg.de!zib-berlin.de!news.rrz.uni-hamburg.de!unibwh.unibw-hamburg.de!Germany.EU.net!EU.net!howland.reston.ans.net!gatech!nntp.msstate.edu!paladin.american.edu!auvm!RELAY.RELAY.COM!PHILS

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit
X-Google-Thread: 11353d,766dc03db97c440a
X-Google-Attributes: gid11353d,public
X-Google-ArrivalTime: 1995-03-21 12:28:59 PST
Path: arc1-ca.pugleaf.net!nntp.gmd.de!news.rwth-aachen.de!news.rhrz.uni-bonn.de!RRZ.Uni-Koeln.DE!uni-duisburg.de!zib-berlin.de!news.rrz.uni-hamburg.de!unibwh.unibw-hamburg.de!Germany.EU.net!EU.net!howland.reston.ans.net!gatech!nntp.msstate.edu!paladin.american.edu!auvm!RELAY.RELAY.COM!PHILS
Comments: Gated by NETNEWS@AUVM.AMERICAN.EDU
Newsgroups: bit.listserv.script-l
Message-ID: <PHILS.950321152859@relay.relay.com>
Date: Tue, 21 Mar 1995 15:28:59 EST
Sender: IBM vs Waterloo SCRIPT discussion group <SCRIPT-L@uga.cc.uga.edu>
From: "Philip H. Smith III, 703 506-0500" <PHILS@RELAY.RELAY.COM>
Subject: Re: Problem about printing Lucida Math Symbol
Lines: 191