Can I Not save the image returned?

23 views
Skip to first unread message

Eduardo

unread,
Jul 6, 2010, 9:58:09 AM7/6/10
to CairoPlot
Hi folks, I'm trying the CairoPlot and found it amazing.
I'll be using it with Django, to generate some reports for financial
market.

What I need is to ask CairoPlot or even cairo itself to not save the
image, but to return it, for me to change the mime type and return it
in a HttpResponse.

I'm reading the Cairo docs and still got nothing that clarify this
subject to me.
If anybody can help, I'd be glad.

Thank you

Eduardo

Eduardo

unread,
Jul 7, 2010, 3:05:40 PM7/7/10
to CairoPlot
Fixed...

Is just pass to the write_to_png method, a buffer like StringIO...and
return it to the caller.

Rodrigo Araújo

unread,
Jul 7, 2010, 7:11:01 PM7/7/10
to cair...@googlegroups.com
Nice, I actually didn't know it was possible.

Rodrigo

--
You received this message because you are subscribed to the Google Groups "CairoPlot" group.
To post to this group, send email to cair...@googlegroups.com.
To unsubscribe from this group, send email to cairoplot+...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/cairoplot?hl=en.


Reply all
Reply to author
Forward
0 new messages