diff options
Diffstat (limited to 'Master/tlpkg/tlgs/Resource/Init/gs_fonts.ps')
-rw-r--r-- | Master/tlpkg/tlgs/Resource/Init/gs_fonts.ps | 19 |
1 files changed, 12 insertions, 7 deletions
diff --git a/Master/tlpkg/tlgs/Resource/Init/gs_fonts.ps b/Master/tlpkg/tlgs/Resource/Init/gs_fonts.ps index 38f0f6ca26f..803faca4918 100644 --- a/Master/tlpkg/tlgs/Resource/Init/gs_fonts.ps +++ b/Master/tlpkg/tlgs/Resource/Init/gs_fonts.ps @@ -372,8 +372,12 @@ FONTPATH length 0 eq { (%END FONTPATH) .skipeof } if % of strings: what the system thinks is the ps name, % and the access path. /.setnativefontmapbuilt { % set whether we've been run - systemdict exch /.nativefontmapbuilt exch .forceput -} .bind executeonly def + dup type /booleantype eq { + systemdict exch /.nativefontmapbuilt exch .forceput + } + {pop} + ifelse +} .bind executeonly odef systemdict /NONATIVEFONTMAP known .setnativefontmapbuilt /.buildnativefontmap { % - .buildnativefontmap <bool> systemdict /.nativefontmapbuilt .knownget not @@ -418,6 +422,7 @@ systemdict /NONATIVEFONTMAP known .setnativefontmapbuilt //true .setnativefontmapbuilt } ifelse } bind def +currentdict /.setnativefontmapbuilt .forceundef % Create the dictionary that registers the .buildfont procedure % (called by definefont) for each FontType. @@ -578,7 +583,7 @@ buildfontdict 3 /.buildfont3 cvx put } bind def /.setloadingfont { //systemdict /.loadingfont 3 -1 roll .forceput -} .bind odef % .forceput must be bound and hidden +} .bind executeonly odef % .forceput must be bound and hidden /.loadfont { % Some buggy fonts leave extra junk on the stack, % so we have to make a closure that records the stack depth @@ -1007,7 +1012,7 @@ $error /SubstituteFont { } put dup length string copy .forceput setglobal } ifelse -} .bind odef % must be bound and hidden for .forceput +} .bind executeonly odef % must be bound and hidden for .forceput % Attempt to load a font from a file. /.tryloadfont { % <fontname> .tryloadfont <font> true @@ -1098,7 +1103,7 @@ $error /SubstituteFont { } put % Check to make sure the font was actually loaded. dup 3 index .fontknownget - { dup /PathLoad 4 index //.putgstringcopy exec + { dup /PathLoad 4 index .putgstringcopy 4 1 roll pop pop pop //true exit } if @@ -1110,7 +1115,7 @@ $error /SubstituteFont { } put { % Stack: origfontname fontdirectory path filefontname 2 index 1 index .fontknownget { % Yes. Stack: origfontname fontdirectory path filefontname fontdict - dup 4 -1 roll /PathLoad exch //.putgstringcopy exec + dup 4 -1 roll /PathLoad exch .putgstringcopy % Stack: origfontname fontdirectory filefontname fontdict 3 -1 roll pop % Stack: origfontname filefontname fontdict @@ -1143,7 +1148,7 @@ $error /SubstituteFont { } put } loop % end of loop - } bind executeonly def % must be bound and hidden for .putgstringcopy + } bind executeonly odef % must be bound and hidden for .putgstringcopy currentdict /.putgstringcopy .undef |