🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.lang.postscript
Article #8213

character outlines or printing DRAFT in outline

#8213
From: Vince Pugliese
Date: Mon, 10 Apr 1989 20:50
73 lines
1804 bytes

%% have fun with this guys

%% outline font program 
%% Postscript Language Tutorial and Cookbook
%% page 203

/makeoutlinedict 7 dict def
/MakeOutlineFont
 {makeoutlinedict begin
  /uniqueid exch def
  /strokewidth exch def
  /newfontname exch def
  /basefontname exch def

  /basefontdict basefontname findfont def

  /numentries basefontdict maxlength 1 add def

  basefontdict /UniqueID known not
   { /numentries numentries 1 add def } if

     /outfontdict numentries dict def
  
   basefontdict
    { exch dup /FID ne
     { exch outfontdict 3 1 roll put }
     { pop pop }
    ifelse
    } forall
 
  outfontdict /FontName newfontname put
  outfontdict /PaintType 2 put
  outfontdict /StrokeWidth strokewidth put
  outfontdict /UniqueID uniqueid put
  
  newfontname outfontdict definefont pop
  end

} def

% 120 seems to give light enough lettering

/Helvetica-Bold /Helvetica-Outline1 1000 120 div

/Helvetica-Bold findfont dup /UniqueID known
 { /UniqueID get 1 add }
 { pop 1 }
 ifelse

MakeOutlineFont 

% borrowed from usenet
% andy malis posting

gsave
initmatrix 72 dup scale
/Helvetica-Outline1 findfont 1 scalefont setfont
(DRAFT) dup
stringwidth pop
4.5   5.5  translate
45 rotate 2 div neg 0 moveto
show
grestore

showpage
  
 

of course you are embedding this in another postscript file then delete the
showpage 
                             hope this helps
Technical Details
Message-ID: <829@mv05.ecf.toronto.edu>
Path: arc1-ca.pugleaf.net!utzoo!utgpu!jarvis.csri.toronto.edu!me!ecf!apollo

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!utgpu!jarvis.csri.toronto.edu!me!ecf!apollo
From: apollo@ecf.toronto.edu (Vince Pugliese)
Newsgroups: comp.lang.postscript
Subject: character outlines or printing DRAFT in outline
Message-ID: <829@mv05.ecf.toronto.edu>
Date: 10 Apr 89 20:50:39 GMT
Organization: Engineering Computing Facility, University of Toronto
Lines: 74