diff options
author | Ray Johnston <ray.johnston@artifex.com> | 2005-04-20 20:05:41 +0000 |
---|---|---|
committer | Ray Johnston <ray.johnston@artifex.com> | 2005-04-20 20:05:41 +0000 |
commit | 25edfbef989569acc07cda5e27e2261fc31ab6ac (patch) | |
tree | 709a7f1de50b210b2c4a73532ee317abfd123523 /gs/src/zbfont.c | |
parent | 07e522f84f038c50c14329417087794b5f242018 (diff) |
Use the OrigFontName from an embedded font's FOntInfo dictionary since this
is where Windows PostScript dirver puts the real font name when embedding
fonts. Bug 688006 for customer 32.
git-svn-id: http://svn.ghostscript.com/ghostscript/trunk@5862 a1074d23-0009-0410-80fe-cf8c14f379e6
Diffstat (limited to 'gs/src/zbfont.c')
-rw-r--r-- | gs/src/zbfont.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/gs/src/zbfont.c b/gs/src/zbfont.c index be5009fda..7580f6a1b 100644 --- a/gs/src/zbfont.c +++ b/gs/src/zbfont.c @@ -534,7 +534,11 @@ sub_font_params(const gs_memory_t *mem, const ref *op, gs_matrix *pmat, gs_matri ) memset(pomat, 0, sizeof(*pomat)); } - if (dict_find_string((porigfont != NULL ? porigfont : op), ".Alias", &pfontname) > 0) { + /* Use the FontInfo/OrigFontName key preferrentially (created by MS PSCRIPT driver) */ + if ((dict_find_string((porigfont != NULL ? porigfont : op), "FontInfo", &pfontname) > 0) && + (dict_find_string(pfontname, "OrigFontName", &pfontname) > 0)) { + get_font_name(mem, pfname, pfontname); + } else if (dict_find_string((porigfont != NULL ? porigfont : op), ".Alias", &pfontname) > 0) { /* If we emulate the font, we want the requested name rather than a substitute. */ get_font_name(mem, pfname, pfontname); } else if (dict_find_string((porigfont != NULL ? porigfont : op), "FontName", &pfontname) > 0) { |