Skip to content

Allow resizing figures in notebook #1193

Closed

Description

@szhorvat

This is a feature request.

matplotlib figures are interactive when using the default backend. If would be useful have have at least the resizing functionality in the notebook interface.

It would be nice to have resizeable figures in the notebook interface, at least in the cases where it's easy to implement (is it possible to do it e.g. for SVG output only?)

Activity

  1. ellisonbg commented on Jan 5, 2012

    @ellisonbg
    Member

    I think this is something we can do.

  2. cschin commented on Feb 29, 2012

    @cschin
  3. Sharpie commented on Feb 29, 2012

    @Sharpie

    The mplh5canvas features list doesn't look too encouraging:

    Firefox is not supported and Internet Explorer will never be supported.

    Ouch.

  4. cschin commented on Feb 29, 2012

    @cschin

    I think they use websocket for frontend/backend communication. If we can replace that with ipython's one... , I can help to take a look some time in the furture

  5. mcelrath commented on Jun 8, 2012

    @mcelrath

    See #1881 for improving/switching to SVG matplotlib output.

    Scaling SVG plots holding the aspect ratio fixed is possible now just using CSS. Changing the aspect ratio requires requesting matplotlib to re-plot. Zooming or panning (as is possible in the matplotlib gtk/qt interface) is not currently possible, and would require writing a new backend along the lines of mplh5canvas.

  6. ellisonbg commented on Jun 8, 2012

    @ellisonbg
    Member

    We can do zooming and panning with the current inline backend and a JavaScript widget that uses our display system. It shouldn't be too bad actually.

  7. SylvainCorlay commented on Sep 16, 2013

    @SylvainCorlay
    Member

    Hi,
    I am coming back on this old issue as mplh5canvas is mentioned.
    Is there any plan in the future to either

    • integrate the matplotlib html5 backend with the notebook,
    • integrate the matplotlib qt backend with the qt console
      for inline plots, rather than only relying on the static png images?

    Best,
    Sylvain

  8. Carreau commented on Sep 16, 2013

    @Carreau
    Member
    1. yes in a more general way, enable js<>kerel (didn't say python) communications
    2. No.

    Envoyé de mon iPhone

    Le 16 sept. 2013 à 21:05, Sylvain Corlay [email protected] a écrit :

    Hi,
    I am coming back on this old issue as mplh5canvas is mentioned.
    Is there any plan in the future to either

    integrate the matplotlib html5 backend with the notebook,
    integrate the matplotlib qt backend with the qt console for inline plots, rather than only relying on the static png images?
    Best,
    Sylvain

    —
    Reply to this email directly or view it on GitHub.

  9. SylvainCorlay commented on Sep 16, 2013

    @SylvainCorlay
    Member
    1. I saw (and tried) the pull request 4195, but the example relies on an other js plotting library rather than leveraging matplotlib with a potential html/js backend.
    2. Too bad!
  10. damianavila commented on Feb 1, 2014

    @damianavila
    Member

    In current master, the figure are resizeable inside the notebook, so probably we can close this one...

  11. startakovsky commented on Jul 26, 2015

    @startakovsky

    @damianavila Is this still true? Running IPython Notebook 3.0.1 here..... Vanilla install. Ubuntu.

    This is not resizable from the notebook:

    from IPython.core.display import Image
    Image('http://www.cliffsofmoher.ie/wp-content/uploads/2013/09/sept242013paki.png')

  12. damianavila commented on Jul 29, 2015

    @damianavila
    Member

    @damianavila Is this still true?

    I don't think so... IIRC, there was some problem with the re sizing and we defined to have no resizable figures... let me find the issues/PRs... OK here: #8098 and here: #8062

  13. startakovsky commented on Jul 31, 2015

    @startakovsky

    @damianavila Thanks.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

      Milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions