[IPython-dev] Matplotlib HTML5 canvas
Mon Aug 27 04:42:17 CDT 2012
> From: Bob McElrath <email@example.com (mailto:firstname.lastname@example.org)>
> Ah ok then this is nothing new. Mplh5canvas has a separate HTTP server that
> serves up the HTML5 canvas (and so does iPython -- making the two difficult to
> work together). Was the talk just showing existing mplh5canvas functionality?
> Or have they done something new that makes it work better with iPython?
Simon and I integrated the mplh5canvas with the IPython notebook while we were at EuroSciPy, which required some (small) changes to IPython. Previously the canvas opened in a separate browser window instead of in the notebook itself. We also added panning and a cursor returning data coordinates.
It is still a very loose integration based on the separate HTTP server that you mention, but it should be easy to slipstream the communication over IPython's own websockets. This would avoid cross-site scripting restrictions and allow the figure to be resized within the notebook instead of only within its iframe, for example. The dual-server approach works quite well otherwise (though it's clearly sub-optimal).
We wanted to get people interested and show them what's already possible in the notebook, so this was more a proof of concept. I'm sure Simon can make the relevant IPython changes available somewhere too.
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the IPython-dev