MyST-NB icon indicating copy to clipboard operation
MyST-NB copied to clipboard

LaTeX text rendered as math (nowrap=False in render_text_latex)

Open amcdawes opened this issue 4 years ago • 2 comments

Describe the problem

Some Jupyter notebooks output LaTeX that includes both text and math (see the QuTiP package for example). Myst-nb renders this as all math by wrapping with \begin{split} and \end{split}.

This is not consistent with the behavior of the jupyter notebook environment.

It seems like either setting nowrap=True or allowing an override would be ideal.

Link to your repository or website

https://github.com/amcdawes/qutip-book/issues/6

Steps to reproduce

  1. Include QuTiP output in a jupyter book notebook
from qutip import *
qeye(2)
  1. Build jb build qutip-book

The version of Python you're using

3.7.10

Your operating system

Mac OSX 11.6

Versions of your packages

Jupyter Book : 0.12.1 External ToC : 0.2.3 MyST-Parser : 0.15.2 MyST-NB : 0.13.1 Sphinx Book Theme : 0.1.7 Jupyter-Cache : 0.4.3 NbClient : 0.5.3 QuTiP: 4.6.2

Additional context

I also opened this on jupyter-book, I was not sure where best to raise the issue (https://github.com/executablebooks/jupyter-book/issues/1595)

amcdawes avatar Jan 10 '22 14:01 amcdawes

Thanks for opening your first issue here! Engagement like this is essential for open source projects! :hugs:
If you haven't done so already, check out EBP's Code of Conduct. Also, please try to follow the issue template as it helps other community members to contribute more effectively.
If your issue is a feature request, others may react to it, to raise its prominence (see Feature Voting).
Welcome to the EBP community! :tada:

welcome[bot] avatar Jan 10 '22 14:01 welcome[bot]