[cairo] Text output under angle - uneven text

Jonathan Morton jonathan.morton at movial.com
Tue Feb 2 05:19:20 PST 2010

On Tue, 2010-02-02 at 09:14 -0400, cu wrote:
> Thanks, that explains it. I have seen this issue mentioned on the
> list, but never considered what it means to the output, until I tried
> it.
> Is the subpixel positioning for text something that is in plans for a
> future version? Soon/not soon/never?

You can fake it by the old supersampling technique - render the text to
something that's much bigger than you need, and then scale the result
down.  Whether that's faster than the text-as-path method remains to be
seen, but it's entirely possible.

You'll also need enough memory to hold the larger image.  Further, there
is a limit on the size of image you can make (about 32k pixels width or
height is probably safe).

Another technique is to render the text straight and level, and then
rotate the resulting image.  The image should be slightly larger than
the result (up to 2x) to avoid aliasing, but there's no benefit to going
crazy.  If you plan on animating, that might be the best answer.

From: Jonathan Morton
      jonathan.morton at movial.com

More information about the cairo mailing list