ipython / ipython

Official repository for IPython itself. Other repos in the IPython organization contain things like the website, documentation builds, etc.
https://ipython.readthedocs.org
BSD 3-Clause "New" or "Revised" License
16.31k stars 4.45k forks source link

Inline math sequences shouldn't affect markdown code editor formatting. #4850

Closed ngoldbaum closed 2 weeks ago

ngoldbaum commented 10 years ago

This comes up when trying to write a technical document in the notebook. In the example pasted below, the underscores are parsed as markdown formatting sequences even though they are inside an inline latex math block. This doesn't affect the output of the markdown cell, but is visually distracting when editing markdown that has inline latex. image

Not sure if this is a bug in IPython or an external code highlighting library. This is in master.

minrk commented 10 years ago

While-editing issues are generally due to CodeMirror, though there could be some configuration that we aren't aware of (such as a markdown+math mode, as opposed to plain markdown).

ellisonbg commented 10 years ago

I think to fix this we would need to improve the CodeMirror Markdown syntax highlighter to know about math sections. Probably not trivial...

jklymak commented 10 years ago

I'd be happy with the ability to change the syntax-highlighter to Latex.