[cairo] Text scaling and hinting
rocallahan at novell.com
Wed May 4 18:53:47 PDT 2005
On Wed, 2005-05-04 at 21:14 -0400, Carl Worth wrote:
> On Thu, 05 May 2005 10:00:28 +1200, Robert O'Callahan wrote:
> > I think I can work around the current Cairo API. String drawing would
> > fix all the glyph positions based on a cairo_scaled_font_t chosen to be
> > the definitive metrics for the font, and then call cairo_show_glyphs.
> If I'm understanding you correctly, that sounds like it's exactly the
> recommended way of using the API.
Yeah, but I'll be using the metrics for a single cairo_scaled_font_t to
place all glyphs even when I may be drawing with a different CTM to the
one the cairo_scaled_font_t was created with ... i.e., I'm drawing
glyphs whose extents may only be hazily related to the extents I used
[OK, I'm lying. In this first iteration I'm using Pango-Xft so I'm not
even using any cairo_scaled_font_t. But hopefully Owen will release some
sort of Pango-Cairo integration to solve this :-).]
> > But I'd certainly prefer to delegate the problem to Cairo, since this
> > solution might be suboptimal in output quality and performance.
> What specifically would you like to see different in the API?
The ability to set a particular cairo_scaled_font_t into a cairo_t with
a guarantee that glyph drawing will use those outlines, or at least
respect those metrics.
More information about the cairo