[NTG-pdftex] [PATCH v3] pdftex - Add support for encfile and \pdfgentounicode for PK fonts
Hans Hagen
pragma at wxs.nl
Tue Mar 28 11:27:03 CEST 2017
On 3/27/2017 11:53 PM, Reinhard Kotucha wrote:
> On 2017-03-27 at 09:59:34 +0200, Pali Rohár wrote:
>
> > Anyway, is there some script or program which can generate any PGC
> > files? Quick look at google does not find anything, even not any
> > specification for that file. I could probably decode it from pdftex
> > source code...
>
> AFAIK the "PDF Font Containers" are not officially maintained. They
> were introduced in order to support development of pdfTeX itself but
> never supposed to be used by mortal users.
We added that as an experiment as part of Thanh's thesis work. It
permitted injection of shapes generated by metapost.
> Instead of using Type3 fonts, you get better results if you create
> Type1 fonts from the Metafont sources.
>
> http://www.tex.ac.uk/FAQ-textrace.html
>
> textrace first used autotrace, later potrace, in order to create Type1
> outlines from high-resolution bitmaps created by Metafont. The
> disadvantage is that the final outlines are not always perferct. I do
> not know how much time Vladimir Volovich spent on manual tweaking when
> he created the CM-Super Type1 fonts. On the other hand, Tigran
> Aivazian converted Yannis Haralambous' Hebrew fonts using textrace for
> his Bible project in 2006 and the result was excellent. AFAIK he
> didn't tweak anything manually.
>
> The main problem with textrace is that I don't know whether this
> program is available anymore. It's not on CTAN, but if it had ever
> been there, I could check my old TeX Collection CDs/DVDs.
>
> Maybe the better choice nowadays is MetaType1. The Metafont source
> files are processed by MetaPost and converted to PostScript. The
> PostScript files are then converted to high-quality Type1 fonts by a
> bunch of scripts. I assume that MetaType1 is quite reliable because
> the Latin Modern fonts were created with MetaType1, presumably without
> manual interaction. After all, MetaType1 is still maintained.
>
> Type3 fonts can contain arbitrary PostScript code. They are just
> collections of pictures. However, the Type3 font format allows to
> assign pictures to characters. Even if glyphs are made up of lines
> and curves, the quality is quite poor. Type1 fonts contain so-called
> "hints" which provide additional information used when glyphs are
> fitted to a grid. The hints make sure that all vertical stems of an
> "m" have the same width, for example.
fwiw: this matters less on modern displays ... i'm not even sure if the
lm / gyre have much hinting in them
> dvips (and later pdftex) used the Type3 font format in order to allow
> bitmaps created with Metafont to be inserted into PostScript or PDF
> files. This was fine at a time when very few Type1 fonts were
> available.
>
> But nowadays I don't see any reason to care about Type3 fonts or "PDF
> Glyph Containers" at all. The best solution is to create Type1 fonts
> from Metafont sources.
it's still interesting to be able to inject arbitrary shapes (with a bit
of packaging in actualtext one can even get cut/paste right)
> If you are successful, please upload the Type1 fonts to CTAN.
Hans
-----------------------------------------------------------------
Hans Hagen | PRAGMA ADE
Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
tel: 038 477 53 69 | www.pragma-ade.nl | www.pragma-pod.nl
-----------------------------------------------------------------
More information about the ntg-pdftex
mailing list