Path: csiph.com!usenet.pasdenom.info!gegeweb.org!de-l.enfer-du-nord.net!feeder2.enfer-du-nord.net!fu-berlin.de!uni-berlin.de!individual.net!not-for-mail From: Helge Blischke Newsgroups: comp.lang.postscript Subject: Re: TrueType CE Encoding Followup-To: comp.lang.postscript Date: Fri, 27 Apr 2012 21:43:40 +0200 Lines: 71 Message-ID: References: Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7Bit X-Trace: individual.net sULiXIXo0fUyiuJzcahkSAnoiYJBEVh//l/rXmQMjFjQtqxGAM Cancel-Lock: sha1:xhB/Ne4NTqSXLk/Ao3Bfcycu7c8= User-Agent: KNode/0.99.01 Xref: csiph.com comp.lang.postscript:667 Gerhard Trummer wrote: > Hi, > > I'm trying to change the encoding vector to CE for Arial-Black. > According to the PLRM Ex. 5.8: > > %!PS-Adobe-3.0 > > /Arial-Black findfont > dup length dict begin > {1 index /FID ne > {def} > {pop pop} ifelse} forall > /Encoding CE def > currentdict > end > /ArialBlackCE exch definefont pop > > /ArialBlackCE findfont > 15 scalefont setfont > 30 800 moveto > (\310\311\312\313\314\315\316\317) show > > showpage > > Unfortunately there is no CE encoding: > > gs -r72 -sPAPERSIZE=a4 > GPL Ghostscript 9.04 (2011-08-05) > Copyright (C) 2011 Artifex Software, Inc. All rights reserved. > This software comes with NO WARRANTY: see the file PUBLIC for details. > GS>(/tmp/ps-run-15301X5g) run > Can't find (or can't open) font file > /usr/share/ghostscript/9.04/Resource/Font/Arial-Black. > Can't find (or can't open) font file Arial-Black. > Querying operating system for font files... > Loading Arial-Black font from > /usr/share/fonts/truetype/msttcorefonts/ariblk.ttf... 3540104 2107745 > 5487080 3235205 1 done. > Error: /undefined in CE > Operand stack: > Encoding > Execution stack: > %interp_exit .runexec2 --nostringval-- --nostringval-- > --nostringval-- 2 %stopped_push --nostringval-- --nostringval-- > %loop_continue --nostringval-- --nostringval-- false 1 > %stopped_push .runexec2 --nostringval-- --nostringval-- > --nostringval-- 2 %stopped_push --nostringval-- 1910 1 3 > %oparray_pop 1909 1 3 %oparray_pop 1893 1 3 %oparray_pop > 1787 1 3 %oparray_pop --nostringval-- %errorexec_pop > .runexec2 --nostringval-- --nostringval-- --nostringval-- 2 > %stopped_push --nostringval-- > Dictionary stack: > --dict:1159/1684(ro)(G)-- --dict:0/20(G)-- --dict:77/200(L)-- > --dict:14/15(L)-- > Current allocation mode is local > Current file position is 137 > GS<1> > > What am I doing wrong and what is the right solution? > > Thanks in advance, > G. I guess you'll need to consult the PLRM, 3rd ed., appendix E, Character Sets and Encoding Vectors and set up the CE encoding array in PostScript syntax by yourself. Helge