开发者

Can Cairo (the graphics library) be used to render mathematical formulas and pictures (latex style)?

开发者 https://www.devze.com 2023-03-22 14:08 出处:网络
Does it need any dependencies for full-fledged unicode character rendering, o开发者_如何学JAVAr can it read and render any platform\'s (Linux/Max/Windows) native font glyphs without much problems?

Does it need any dependencies for full-fledged unicode character rendering, o开发者_如何学JAVAr can it read and render any platform's (Linux/Max/Windows) native font glyphs without much problems?

Can it import/render eps/pdf/svg inside a produced pdf file, or would I have to manually parse the image file, and redraw it in Cairo?


Cairo per se does not do "formulas" - it can work with the full set of unicode characters, but I think text support is better if you use the "pango" library along with Cairo.

As for importing a vector format, there is "librsvg" which works along with cairo enabling it to be used to render SVG files - this lets up to other libraries - maybe Tex itself, to render mathematical formulas themselves.

As for Pictures, yes, Cairo can import and draw raster pictures on itself.

I have an example of using librsvg with Cairo on this answer, though it is in Python, not in C. You will have to look for the online docs on both libraries to get examples of it working in C. (I remeber there were such, because there were no Python examples, I had to get this one working from the examples given in C).

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号