summaryrefslogtreecommitdiff
path: root/Master/tlpkg/tlgs/Resource/Init/gs_fonts.ps
diff options
context:
space:
mode:
Diffstat (limited to 'Master/tlpkg/tlgs/Resource/Init/gs_fonts.ps')
-rw-r--r--Master/tlpkg/tlgs/Resource/Init/gs_fonts.ps23
1 files changed, 21 insertions, 2 deletions
diff --git a/Master/tlpkg/tlgs/Resource/Init/gs_fonts.ps b/Master/tlpkg/tlgs/Resource/Init/gs_fonts.ps
index 8e361552bc8..3f4f4af8066 100644
--- a/Master/tlpkg/tlgs/Resource/Init/gs_fonts.ps
+++ b/Master/tlpkg/tlgs/Resource/Init/gs_fonts.ps
@@ -1,4 +1,4 @@
-% Copyright (C) 2001-2019 Artifex Software, Inc.
+% Copyright (C) 2001-2020 Artifex Software, Inc.
% All Rights Reserved.
%
% This software is provided AS-IS with no warranty, either express or
@@ -69,7 +69,7 @@ end def
% <dir.../base.extn> .basename <dir>
/.splitdirname {
(/) rsearch { //true } { (\\) rsearch } ifelse
- {3 -2 roll pop pop //true}{//false} ifelse
+ {exch concatstrings exch pop //true}{//false} ifelse
} bind def
% <dict> .addfontmappermitpaths
@@ -1056,6 +1056,25 @@ $error /SubstituteFont { } put
//false
}ifelse
+ % If just opening the file didn't work, try opening the file name
+ % in the font resource directory
+ {
+ dup
+ //.fonttempstring /FontResourceDir getsystemparam .genericrfn
+ (r) { file } stopped {
+ pop pop //true
+ } {
+ dup .filename
+ { 3 -1 roll pop exch }
+ { pop }
+ ifelse
+ //false
+ } ifelse
+ }
+ {
+ //false
+ }ifelse
+
{
QUIET not
{ (Can't find \(or can't open\) font file ) print dup print