[gs-bugs] [Bug 690446] New: Arial-BoldMT Error: /undefined in findresource

bugs.ghostscript.com-bugzilla-daemon at ghostscript.com bugs.ghostscript.com-bugzilla-daemon at ghostscript.com
Thu Apr 23 07:53:27 PDT 2009


http://bugs.ghostscript.com/show_bug.cgi?id=690446

           Summary: Arial-BoldMT Error: /undefined in findresource
           Product: Ghostscript
           Version: 8.64
          Platform: PC
        OS/Version: Windows XP
            Status: UNCONFIRMED
          Severity: normal
          Priority: P4
         Component: PDF Interpreter
        AssignedTo: alex.cherepanov at artifex.com
        ReportedBy: serge_gubenko at hotmail.com
         QAContact: gs-bugs at ghostscript.com


This issue seem to be related to bug#689956 and bug#689623. I was trying to 
view the document using the 

gswin32c -dSAFAER -dBATCH test_16.pdf

command (test file is attached). The output log was:

GPL Ghostscript 8.64 (2009-02-03)
Copyright (C) 2009 Artifex Software, Inc.  All rights reserved.
This software comes with NO WARRANTY: see the file PUBLIC for details.
Processing pages 1 through 1.
Page 1
Can't find CID font "Arial-BoldMT".
Substituting CID font /Adobe-Identity for /Arial-BoldMT, see doc/Use.htm#CIDFont
Substitution.
The substitute CID font "Adobe-Identity" is not provided either. Will exit with
error.
Error: /undefined in findresource
Operand stack:
   --nostringval--   --dict:6/15(L)--   F1   8   --dict:6/6(L)--   --dict:6/6(L)
--   Arial-BoldMT   --dict:11/12(ro)(G)--   --nostringval--   CIDFontObject   --
dict:8/8(L)--   --dict:8/8(L)--   Adobe-Identity
Execution stack:
   %interp_exit   .runexec2   --nostringval--   --nostringval--   --nostringval-
-   2   %stopped_push   --nostringval--   --nostringval--   --nostringval--   fa
lse   1   %stopped_push   1862   1   3   %oparray_pop   1861   1   3   %oparray_
pop   1845   1   3   %oparray_pop   --nostringval--   --nostringval--   2   1
1   --nostringval--   %for_pos_int_continue   --nostringval--   --nostringval--
  --nostringval--   --nostringval--   %array_continue   --nostringval--   false
  1   %stopped_push   --nostringval--   %loop_continue   --nostringval--   --nos
tringval--   --nostringval--   --nostringval--   --nostringval--   --nostringval
--   %array_continue   --nostringval--   --nostringval--   --nostringval--   --n
ostringval--   --nostringval--   %loop_continue
Dictionary stack:
   --dict:1150/1684(ro)(G)--   --dict:1/20(G)--   --dict:74/200(L)--   --dict:74
/200(L)--   --dict:106/127(ro)(G)--   --dict:280/300(ro)(G)--   --dict:22/25(L)-
-   --dict:4/6(L)--   --dict:21/40(L)--   --dict:1/1(ro)(G)--   --dict:8/8(L)--
Current allocation mode is local
Last OS error: No such file or directory
GPL Ghostscript 8.64: Unrecoverable error, exit code 1

First I tried to edit the cidfmap file adding following lines there:
/Arial-BoldMT  			<< /FileType /TrueType /Path 
(C:/WINDOWS/Fonts/ARIALBD.TTF)  /SubfontID 0  /CSI [(Unicode) 0] >> ;
/Arial-ItalicMT			<< /FileType /TrueType /Path 
(C:/WINDOWS/Fonts/ARIALI.TTF)  /SubfontID 0  /CSI [(Unicode) 0] >> ;
/ArialMT  				<< /FileType /TrueType /Path 
(C:/WINDOWS/Fonts/arial.ttf)  /SubfontID 0  /CSI [(Unicode) 0] >> ;
/TimesNewRomanPSMT  	<< /FileType /TrueType /Path 
(C:/WINDOWS/Fonts/timesi.ttf)  /SubfontID 0  /CSI [(Unicode) 0] >> ;

This will allow the document to be rendered correctly but symbols were not 
readable, I tried to play with encoding setting but no luck, same unreadable 
symbols displayed.

Then I to defined a small dictionary:

/tempfontsdict 1 dict def tempfontsdict 
begin 
 /Arial-BoldMT       (C:/WINDOWS/Fonts/ARIALBD.TTF)  def
 /Arial-ItalicMT     (C:/WINDOWS/Fonts/ARIALI.TTF)  def 
 /ArialMT            (C:/WINDOWS/Fonts/arial.ttf)  def 
 /TimesNewRomanPSMT  (C:/WINDOWS/Fonts/timesi.ttf)  def 
End

And changed the pdf_font.ps:

       dup /FontFile knownoget not {
		  dup /FontFile2 knownoget not {
			dup /FontFile3 knownoget not {
				%//null			  		
	    
	+			dup /FontName get 
	+			/tempFontName exch def
	+			tempfontsdict tempFontName known {
	+				dup /FontName get (Custom font change:) 
print == 
	+				tempfontsdict tempFontName get
	+				/tempFontFile exch def			
	 
	+				dup /FontFile3 << /F tempFontFile >> 
put     				 
	+				dup /FontFile3 get
	+			} {
	+				//null
	+			} ifelse				
            } if
          } if
        } if

This solved the problem but doesn’t look like a good solution for the issue.



------- You are receiving this mail because: -------
You are the QA contact for the bug, or are watching the QA contact.



More information about the gs-bugs mailing list