[cairo] is unaligned text possible?

Behdad Esfahbod behdad at behdad.org
Mon Dec 16 21:18:29 PST 2013


On 13-12-17 12:11 AM, David Vanderson wrote:
> Hello,
> 
> I'm trying to render text not aligned to pixel boundaries:
> 
> cairo_move_to (cr, 100.3, 100.3);
> cairo_show_text (cr, "hello");
> 
> It seems that regardless of the font options I set, the baseline (for
> instance) is always snapped to a whole pixel. I'm sorry if this is a known
> issue, but is this intentional?

It's a limitation of the current implementation.  Your best bet is to set the
right font options, then do a cairo_text_path();cairo_fill().

> Thanks,
> Dave

-- 
behdad
http://behdad.org/


More information about the cairo mailing list