library for text rendering that supports text-on-path

这一生的挚爱 提交于 2019-12-01 09:56:16

问题


I need a good, reliable library or toolchain for programatically rendering text to png, with different sizes, fonts, weights, etc. It also needs to be able to render text in an arc or to a path. I would like it to be fast, because I'd be running it as on a server.

I've tried using SVG and librsvg, but that doesn't render <textPath> elements.

I've tried pycairo, but again, the text to path doesn't work great, and everywhere in the cairo documentation it mentions that text-to-path is a "toy" and shouldn't be used for serious applications.

Python bindings would be best, because the server runs python. But I'll take any suggestion.


回答1:


Qt has a SVG module, i believe it supports the textPath element.

http://doc.trolltech.com/4.1/qtsvg.html



来源:https://stackoverflow.com/questions/3119882/library-for-text-rendering-that-supports-text-on-path

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!