jrblevin / markdown-mode

Emacs Markdown Mode
http://jblevins.org/projects/markdown-mode/
GNU General Public License v3.0
890 stars 162 forks source link

markdown-mode doesn't render maths as expected when killing and undoing. #352

Open PhoenixStarEclipse opened 6 years ago

PhoenixStarEclipse commented 6 years ago

Expected Behavior

Markdown-mode should render maths properly when killing and undoing.

Actual Behavior

Kill and undo-kill upper multiline equations, and lower multiline equations will get unhighlighted.

Steps to Reproduce

  1. type
    
    $$a
    b$$

$$c d$$

and make sure that there's an empty line between the two equations.
2. Kill lines `$$a` and `b$$`.
3. Undo the two kills by pressing C-/.
4. 

$$a b$$


gets and remains unhighlighted.

## Software Versions

<!--
Use M-x markdown-show-version and M-x emacs-version to determine the
Markdown Mode and Emacs version numbers.

Examples:

- Markdown Mode: From Git on 2017-10-17, 2.4-dev, or 2.3
- Emacs: 25.3.2
- OS: macOS High Sierra
-->

- Markdown Mode: `2.4-dev`
- Emacs: `GNU Emacs 25.3.1 (x86_64-pc-linux-gnu, GTK+ Version 3.22.30) of 2018-07-22`
- OS: `Linux AprilGrimoire 4.14.52-gentoo #1 SMP Sat Jul 28 20:31:00 CST 2018 x86_64 Intel(R) Core(TM) i7-8700K CPU @ 3.70GHz GenuineIntel GNU/Linux`
PhoenixStarEclipse commented 6 years ago
$a$b$c$

is also not properly highlighted. Only a is highlighted, instead of both a and c.

syohex commented 4 years ago

I have merged #487. I suppose https://github.com/jrblevin/markdown-mode/issues/352#issuecomment-409826496 issue is fixed. Please check latest version.

syohex commented 4 years ago

I suppose this issue is emacs problem, not markdown-mode.