openPMD / openPMD-viewer

:snake: Python visualization tools for openPMD files
https://openpmd-viewer.readthedocs.io/
Other
67 stars 50 forks source link

Fix figure display, when using %matplotlib widget #432

Closed RemiLehe closed 2 weeks ago

RemiLehe commented 3 weeks ago

In general, using %matplotlib widget or %matplotlib ipympl should be almost equivalent (see https://github.com/matplotlib/ipympl/issues/529). However, when using openPMD-viewer, the slider works fine when doing %matplotlib ipympl, but does not when doing %matplotlib widget (i.e. the figures are not displayed, when doing `%matplotlib widget).

This PR fixes the issue.