Re: Pango and non-system fonts



On 8/22/07, Behdad Esfahbod <behdad behdad org> wrote:
> On Wed, 2007-08-22 at 11:55 -0400, Mike Branciforte wrote:
> > We are exploring the possibility of using Cairo+Pango to render pages
> > from a PDF document.
>
> You don't need / shouldn't use pango for rendering PDF.  Pango is used
> to convert characters to glyphs and to lay text out.  PDF on the other
> hand, includes layed-out glyphs.  Just show it, using
> cairo_show_glyphs()

You lost me. Where are the "layed-out glyphs" in this PDF fragment
that would show the string "Where are the glyphs?" in a PDF viewer?

q
BT
50 792 Td
0 -18 Td
/F1 12 Tf
(Where are the glyphs?)Tj
ET
Q

It seems that in order to use cairo_show_glyphs() then I would have to
create an array of glyphs, one "glyph" for each character in the
phrase "Where are the glyphs?"? That means I would have to compute the
x and y position for each glyph? Sounds like a lot of work. Am I
missing something?

Mike



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]