[cairo] Observations from a newb
Donn
donn.ingle at gmail.com
Thu Nov 8 02:20:52 PST 2007
> I don't know if there would be interest in two versions of cairo?
> cairo-core = same as now
> cairo-framework = cairo+pango+librsvg+canvas/scenegraph (in one virtual
> library)
> Since most people expect cairo-framework but get cairo-core plus build
> your own framework.
I see your point. Yes, a cairo-framework would be a good idea. Something fast
with Python bindings. I don't know if things like goocanvas, hippo, sugar are
trying to do this. (I can't run any of them due to old libs etc. on my old
distro.)
> You must remember that cairo follows the simple is beautiful and no
> duplication philosophy. It does not duplicate when other free
> libraries can do the same and better.
Sure, but sometimes it gets fuzzy. "Drawing" implies putting stuff down on a
surface. It gets weird when you need to put stuff down that you have in mind
but have to go fishing around and joining other libs to cairo.
> 1. ctx.draw_svg(<svg object>)
> - librsvg is very good,has a liberal license and draws using cairo so
> there is no need to duplicate.
I can't get it to work. Would love to see what it does.
> - My wishlist however is to have librsvg output to cairo commands or
> capture the commands somehow, so i can compile in svg art without the
> librsvg dependency.
Yes - this is what I am muddling with right now. Well, not librsvg, but to
open an svg file, parse it to some extent and then produce a string of
<pycairo commands> that can be drawn later with exec.
This is what led me to think that an <svg object> could fit into cairo's
purview -- if seen as a "collection" of smaller cairo commands. SVG and cairo
just seem so well matched.
> 2. Other image file formats - GIF,JPG
> - cairo is mostly a drawing/rendering library and as such file formats
> is not really part of the statement of intent
I don't quite understand that. Coming from the "Cairo draws stuff" pov again:
images *are* stuff.
> - cairo does provide a get image data api so you can eg: use PIL in
> python to save/load to any format you desire.
Will have a look in due course.
> 3. cairo is not a font library
> - pango is awesome just wish it was a little faster on latin text :-)
> - I sympathize with people who are trying to use custom fonts with
> cairo since it can be a pain and not always accessible from python.
Yes, it's always amazed me that fonts on Gnu/Linux are so divorced from an
actual font file!
\d
More information about the cairo
mailing list