Hi, Andy (and anyone interested in PDF generation)--

On Thu, Dec 13, 2012 at 8:18 AM, Andy Bennett <[email protected]>wrote:


> > 2. Part of the reason I abandoned the porting effort was that I need a
> > PDF library that can embed arbitrary fonts. I was considering adding
> > that functionality to the egg, but I looked through the PDF spec and
> > never found an explanation of how to obtain the font data to embed
> > (though, as you may be aware, it's a thick book, and it's quite possible
> > I missed something). It has occured to me that possibly you just open
> > the font file and write the bytes into a stream object ... but that
> > can't be the whole answer, because there is also subsetting. Do you
> > happen to know how that stuff works?
>
> I am unsure about this either. I'd like better font support but didn't
> know how to generate those arrays. Have you asked the original author?
> Have you tried recreating the existing fonts?


Thanks, and I suppose it wouldn't hurt to ask ... however:

I'm generally reluctant to claim special knowledge about anything, but in
this case it appears I might know something, so bear with me while I play
at being a expert:

Font embedding means that the actual vector data for the glyphs (that's
vector as in vector graphics, not the sequential data structure) is placed
in the PDF file; that way   you ensure that the file will look, and print,
the same on every platform, whether or not the end user has the font. This
PDF library (and I think I've looked at the original Common Lisp version,
though I don't know CL very well) does nothing in the way of embedding. The
'font-info' vectors you see are just the font metrics for the standard 14
fonts that PDF readers are required to have available. If you stick to
those, you can do a good job of typesetting just based on the metrics, and
the fonts don't need to be embedded because you can assume they are
available to the end user. And if you're a geek writing technical
documentation, that might well be sufficient. What *I* would like to see is
a PDF lib that graphic designers will like--and font embedding is a key
part of that.

The good news is that I took another look at the PDF reference manual, and
I think the info is in there ... but it's all dense technical reference
info, with no straightforward explanation. So I probably need to set aside
a couple of hours to dig in and carefully read it.

--
Matt Gushee
_______________________________________________
Chicken-users mailing list
[email protected]
https://lists.nongnu.org/mailman/listinfo/chicken-users

Reply via email to