PlutoPlotly: save a plot with LaTeX strings

Hi @disberd,

In case someone else has the same problem as myself, I tested your solution on various computers (Windows and Linux), and I can summarize my situation as follows:

  1. I did not need the downgrade of Kaleido_jll. In my case, even if I did so, it did not solve the problem. So, Kaleido_jll@v0.1.0 vs. Kaleido_jll@v0.2.1 was not the main issue in my case.

  2. I need to use both packages: PlutoPlotly and PlotlyKaleido

  3. I need to apply both commands:

    PlotlyKaleido.start(;mathjax = true)
    force_pluto_mathjax_local(true)

    in order to (i) save plots that include LaTeX strings (PlotlyKaleido.start(...)) and (ii) to obtain a visible display of those strings in both the active and static versions of the notebooks (force_pluto_mathjax_local(...)). If I include only the former, saving plots with LaTeX works very well, but no LaTeX strings will appear in the two notebook versions. If I include only the latter, the visible display of those strings works OK in the browser, but no savefig function will be available to save the plots.

  4. My initial problem was that before yesterday, when I started to test your solution, I had never used simultaneously PlotlyKaleido.start(...) and force_pluto_mathjax_local(...), which led to the two polar cases: I could save plots with LaTeX strings in them (and those strings were perfectly rendered), but there would be no visible strings on both notebooks’ versions; and vice versa.

Thanks a lot for your help.

1 Like