[Gs-code-review] A fix for #517474 "Problem with hyphen in PDF using Minion"

Igor V. Melichev igor at artifex.com
Sun Feb 24 03:43:39 PST 2002


Peter,

I like this idea.
Actually I dreamed about something like it.
But probably it needs to reorganize arguments of .type1execchar .

Perhaps my queue now consists of the completion of FAPI, Hinter and gs-cjk
patch.
So Widths to be delayed or to be assigned to someone else.
Would you mind to put your suggestion into Projects.htm ?

Igor.

-----Original Message-----
From: L. Peter Deutsch [mailto:ghost at aladdin.com]
Sent: Saturday, February 23, 2002 7:41 PM
To: igor at artifex.com
Cc: gs-code-review at ghostscript.com
Subject: Re: [Gs-code-review] A fix for #517474 "Problem with hyphen in
PDF using Minion"


This is a reasonable patch, but I'm disturbed that we have to keep piling
one patch on another to address this issue.

I think there are two basic problems here.

1) It seems that many PDF-generating applications are violating the PDF
   specification, which says that the Widths must match the widths in the
   underlying font (i.e., are only a shortcut to help the viewer), and are
   instead either using Widths like Metrics (to override the widths in the
   font) or putting garbage in them (like the 0 values that this patch
   addresses).

2) PostScript's Metrics facility overrides metrics on the basis of glyph
   name, not character code, so we have to resort to hacks to make it work
   for PDF, where Widths is indexed by character code.

We can't do anything about #1.  But we could do something about #2.  We
could add a new (non-standard) .Widths array to the fonts that now can have
a Metrics dictionary, indexed by character code, that the C code would
access directly.  That would get rid of these piled-up patches, and would
add very little code (in fact, it might not net add code at all, because of
the code that we could remove from the PDF interpreter).

What do you think about this idea?

--

L. Peter Deutsch     |    Aladdin Enterprises   |  203 Santa Margarita Ave.
ghost at aladdin.com    |  http://www.aladdin.com  |  Menlo Park, CA 94025

	The future of software is at http://www.opensource.org




More information about the gs-code-review mailing list