Summary: | PDF font woes | ||
---|---|---|---|
Product: | Ghostscript | Reporter: | Lee Howard <faxguy> |
Component: | PDF Interpreter | Assignee: | Default assignee <ghostpdl-bugs> |
Status: | NOTIFIED FIXED | ||
Severity: | normal | ||
Priority: | P4 | ||
Version: | 8.54 | ||
Hardware: | PC | ||
OS: | Linux | ||
Customer: | Word Size: | --- | |
Attachments: |
problem PDF sample
patch |
Description
Lee Howard
2007-01-05 17:22:51 UTC
The file appears to contain a font thet Ghostscript cannot interpret. That's all one can say about the problem without a sample file. Please attach a sample file. Alex, can I send this PDF to you privately? It has information on it that I don't want posted publicly in this forum. You can post an attachment, then "Edit" the attachment to mark it as Private. This does not guarantee privacy, but will restrict the window during which the general public will be able to access the file. Only Artifex engineers and consultants (which includes Alex) can access files marked "Private". Artifex will use care in preserving the confidentiality of any files tagged as "Private", but without a specific NDA, we are liable for any breach of confidentiality. Since Alex is an Artifex engineer, he also cannot accept the file with any conditions for confidentiality. What I suggest is that you create a file that does not contain sensitive information, possibly by editing the original data. You may be able to use the toolbin/pdfinflt.ps to create an non-compressed version which may allow you to edit it without destroying the structure of the PDF (replace sensitive text with blanks). Unless we get a file that can demonstrate the problem we will have to close the bug as INVALID (i.e., the bug submission is incomplete). Created attachment 2673 [details]
problem PDF sample
I was able to remove the confidential parts with hexedit. Thanks. Here it is
now.
Created attachment 2674 [details]
patch
The PDF file is incorrect. Tf operator refers to a font name directly instead
of
using the resource name.
The patch assumes that an unknown resource name is a font name. This fully
recovers the given sample file and avoids a PostScript error in other possible
cases. The patch doesn't affect the normal operation.
Thank you. However, now I see "Error: /undefined in --get--" # gs -sPAPERSIZE=a4 -dBATCH -dNOPAUSE -sDEVICE=faxg3 -sOutputFile=foo.tif foo.pdf GPL Ghostscript 8.54 (2006-05-17) Copyright (C) 2006 artofcode LLC, Benicia, CA. All rights reserved. This software comes with NO WARRANTY: see the file PUBLIC for details. Processing pages 1 through 2. Page 1 Substituting font Helvetica-Bold for X0FU12BP. Loading NimbusSanL-Bold font from /usr/local/share/ghostscript/fonts/n019004l.pfb... 3512016 1659623 1983264 672111 3 done. Substituting font Helvetica-Bold for X0FU09NP. Substituting font Times-Bold for X0GR08NP. Loading NimbusRomNo9L-Medi font from /usr/local/share/ghostscript/fonts/n021004l.pfb... 3553984 1812134 2084184 777137 3 done. Substituting font Times-Bold for X0GR11NP. Substituting font Helvetica-Bold for X0FU08BP. Substituting font Helvetica-Bold for X0FU07NP. Substituting font Times-Bold for X0GR18BP. Substituting font Helvetica-Bold for X0FU10BP. Substituting font Helvetica-Bold for X0FU10NP. Substituting font Helvetica-BoldOblique for X0FU10VP. Loading NimbusSanL-BoldItal font from /usr/local/share/ghostscript/fonts/n019024l.pfb... 3587264 1913685 2427312 1103175 3 done. Page 2 Substituting font Helvetica-Bold for X0FU12BP. Substituting font Helvetica-Bold for X0FU09NP. Substituting font Times-Bold for X0GR08NP. Substituting font Times-Bold for X0GR11NP. Substituting font Helvetica-Bold for X0FU08BP. Substituting font Helvetica-Bold for X0FU07NP. Substituting font Times-BoldItalic for X0GR12IP. Loading NimbusRomNo9L-MediItal font from /usr/local/share/ghostscript/fonts/n021024l.pfb... 3629680 2053847 2417608 1085766 3 done. **** Warning: Tf refers to an unknown resource name: AGaramond-Regular Assuming it's a font name. Can't find (or can't open) font file /usr/local/share/ghostscript/8.54/Resource/Font/AGaramond-Regular. Can't find (or can't open) font file AGaramond-Regular. Querying operating system for font files... Didn't find this font on the system! Substituting font Palatino-Roman for AGaramond-Regular. Loading URWPalladioL-Roma font from /usr/local/share/ghostscript/fonts/p052003l.pfb... 3662960 2224158 2538360 1211484 3 done. Error: /undefined in --get-- Operand stack: --dict:8/8(L)-- 0.999997 --dict:8/8(L)-- 1 MyriadPro-Regular 10 --dict:8/8(L)-- --dict:8/8(L)-- 405431 --dict:8/8(L)-- locatable --dict:8/13(L)-- loca Execution stack: %interp_exit .runexec2 --nostringval-- --nostringval-- --nostringval-- 2 %stopped_push --nostringval-- --nostringval-- --nostringval-- false 1 %stopped_push 1 3 %oparray_pop 1 3 %oparray_pop 1 3 %oparray_pop --nostringval-- --nostringval-- 3 1 2 --nostringval-- %for_pos_int_continue --nostringval-- --nostringval-- --nostringval-- %array_continue --nostringval-- --nostringval-- --nostringval-- --nostringval-- --nostringval-- 5 11 %oparray_pop --nostringval-- false 1 %stopped_push 5 11 %oparray_pop --nostringval-- (gstatetype) --dict:0/0(L)-- --nostringval-- false 1 %stopped_push --nostringval-- %loop_continue --nostringval-- --nostringval-- --nostringval-- --nostringval-- --nostringval-- --nostringval-- --nostringval-- --nostringval-- Dictionary stack: --dict:1123/1686(ro)(G)-- --dict:2/20(G)-- --dict:75/200(L)-- --dict:75/200(L)-- --dict:105/127(ro)(G)-- --dict:253/347(ro)(G)-- --dict:21/24(L)-- --dict:4/6(L)-- --dict:21/32(L)-- --dict:19/21(L)-- --dict:11/13(L)-- --dict:33/50(ro)(G)-- --dict:18/40(L)-- Current allocation mode is local GPL Ghostscript 8.54: Unrecoverable error, exit code 1 The file has another problem in an embedded TrueType font. A work around for several TrueType issues have been added to the current development version. There's no packaged version that can resd the sample file. You need to get the sources by svn co http://svn.ghostscript.com:8080/ghostscript/trunk/gs and compile. Works for me now with SVN code plus the patch. Thanks a lot! The patch is committed as rev. 7663. |