我想检查字体是否存在,然后是否不替代它,并使其可用于文档中字体的每个实例:/ font_a / Font resourcestatus dup {3 1 roll pop pop} if {/ font_a} {/ font_b} ifelse findfont,但是每次使用font_a时我都需要使用它。如何全局定义?
ps.sry表示英语破损
而不是在整个文档中使用findfont
/ scalefont
/ selectfont
,而是在文件开头定义要使用的字体:
/heading-font /Helvetica-Bold findfont 14 scalefont def
/body-font /Times-Roman findfont 11 scalefont def
...
heading-font setfont (Trees) show
body-font setfont (A tree is a tall living structure made of wood.) show
heading-font setfont (Lakes) show
body-font setfont (A lake is a storage medium for water.) show
...
您仍然必须在字体资源中进行搜索,以查看所需的字体是否可用,但是每个字体只需要执行一次。
本文收集自互联网,转载请注明来源。
如有侵权,请联系[email protected] 删除。
我来说两句