[cairo] problem with portability of text extents
Behdad Esfahbod
behdad at behdad.org
Thu Feb 10 20:36:10 PST 2011
On 02/09/11 23:53, John Ellson wrote:
> This maybe a pango problem that I should take elsewhere (?) but I think the
> root cause is in the cairo font backends so I'll ask here first.
>
> The problem I'm having is that the logical_rect returned by
> pango_layout_get_extents() includes whitespace above and below the text when
> using PangoCairoFcFont on Fedora, but not when using PangoCairoATSUIFont on a
> Mac.
Hi John,
This is most probably a bug in pangocairo-atsuifont.c's
pango_cairo_atsui_font_create_base_metrics_for_context().
The ATSUI backend is not well tested and suffers from many problems.
> Would the cairo developers be willing to accept this as a bug, or should I
> attempt to make my own backend-specific compensation to meet my needs in graphviz?
If the ink extents work better, you may want to use those.
Other than that, improvements to the pango code are appreciated, but it's not
something I can work on myself.
behdad
> I'll post or send my test code if anyone asks.
>
> John
>
>
>
> --
> cairo mailing list
> cairo at cairographics.org
> http://lists.cairographics.org/mailman/listinfo/cairo
More information about the cairo
mailing list