[cairo] render text along path

Kevin Atkinson kevin.atkinson at gmail.com
Tue Nov 25 00:51:02 PST 2008


For what I was doing, I actually want the text to warp, so that's all to the
good.

The remaining challenge is warping text along b-splines or beziers.  You'll
note that in the warpedtext.py example, the paths that the text is warped
along are simple little curves - a spiral and a circle.  I want to warp text
along a spline, and so need to parametrize it by arclength, which is not
completely trivial, and generate a normal to the spline.  I've found a
couple useful references in this regard, but if anyone knows of some
existing code that plays nice with cairo already, it would be greatly
appreciated.

Cheers,

Kevin

On Tue, Nov 25, 2008 at 3:34 AM, Dirk Schönberger <
dirk.schoenberger at sz-online.de> wrote:

>
> > Pycairo comes with the example examples/warpedtext.py which draws text
> > along a path.
> >
>
> The example looks interesting.
> The only problem I see is that this method warps the actual glyphs.
> In a pure text on path I think the glyphs should be only rotated,
> transformed or scaled, while the actual "point data" (outlines) are not
> changed.
>
> Regards
> Dirk
>
> _______________________________________________
> cairo mailing list
> cairo at cairographics.org
> http://lists.cairographics.org/mailman/listinfo/cairo
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.cairographics.org/archives/cairo/attachments/20081125/8eaa0ca2/attachment.html 


More information about the cairo mailing list