python: render <svg> via _repr_html_
Work around a recent decision in Jupyter Lab and Notebook to render <svg> is inline <img>, breaking tooltips or text selection. (Rerendering all notebooks was painful.) * NEWS: Mention the change. * python/spot/__init__.py: Add a _repr_html_ method to all classes that had a _repr_svg_. It seems Jupyter will use _repr_html_ by default. * python/spot/jupyter.py: SVG replace the _repr_svg_ method by a _repr_html. * tests/python/_altscc.ipynb, tests/python/_autparserr.ipynb, tests/python/_aux.ipynb, tests/python/_mealy.ipynb, tests/python/_partitioned_relabel.ipynb, tests/python/_product_susp.ipynb, tests/python/_product_weak.ipynb, tests/python/_synthesis.ipynb, tests/python/aliases.ipynb, tests/python/alternation.ipynb, tests/python/atva16-fig2a.ipynb, tests/python/atva16-fig2b.ipynb, tests/python/automata-io.ipynb, tests/python/automata.ipynb, tests/python/cav22-figs.ipynb, tests/python/contains.ipynb, tests/python/decompose.ipynb, tests/python/formulas.ipynb, tests/python/games.ipynb, tests/python/gen.ipynb, tests/python/highlighting.ipynb, tests/python/ltsmin-dve.ipynb, tests/python/ltsmin-pml.ipynb, tests/python/parity.ipynb, tests/python/product.ipynb, tests/python/randaut.ipynb, tests/python/satmin.ipynb, tests/python/stutter-inv.ipynb, tests/python/synthesis.ipynb, tests/python/testingaut.ipynb, tests/python/twagraph-internals.ipynb, tests/python/word.ipynb, tests/python/zlktree.ipynb: Update all notebooks.
This commit is contained in:
parent
4cf7503fff
commit
3034e8fcc3
36 changed files with 43249 additions and 8585 deletions
11
NEWS
11
NEWS
|
|
@ -144,6 +144,17 @@ New in spot 2.11.6.dev (not yet released)
|
|||
- Calling aut.get_hight_state(s) or get.highlight_edge(e) will
|
||||
return the highlight color of that state/edge or None.
|
||||
|
||||
- Recent version Jupyter Notebook and Jupyter Lab started to render
|
||||
SVG elements using <img...> tag to make it easier to copy/paste
|
||||
those image. This breaks several usages, including the
|
||||
possibility to have informative tooltips on states and edges (used
|
||||
in Spot). See the following issues for more details.
|
||||
https://github.com/jupyter/notebook/issues/7114
|
||||
https://github.com/jupyterlab/jupyterlab/issues/10464
|
||||
|
||||
This version of Spot now declares its svg outputs as HTML to
|
||||
prevent Jypyter from wrapping them is images.
|
||||
|
||||
Bugs fixed:
|
||||
|
||||
- tgba_determinize()'s use_simulation option would cause it to
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue