Highlight Markdown Image Starting ! Punctuator (#12841)

* Highlight Markdown Image Starting ! Puctuator

Issue #12835

Adds highlighting for the `!` that defines a markdown image link. This is colored the same as the `[` after it.

Closes #12835

* Fixed highlight test
This commit is contained in:
Matt Bierner
2016-11-07 16:03:49 -08:00
committed by GitHub
parent 6e5c456a2c
commit 3eacbae040
2 changed files with 3 additions and 15 deletions

View File

@@ -1434,8 +1434,7 @@
</dict>
<key>match</key>
<string>(?x:
\! # Images start with !
(\[)((?&lt;square&gt;[^\[\]\\]|\\.|\[\g&lt;square&gt;*+\])*+)(\])
(\!\[)((?&lt;square&gt;[^\[\]\\]|\\.|\[\g&lt;square&gt;*+\])*+)(\])
# Match the link text.
([ ])? # Space not allowed
(\() # Opening paren for url
@@ -1487,7 +1486,7 @@
</dict>
</dict>
<key>match</key>
<string>\!(\[)((?&lt;square&gt;[^\[\]\\]|\\.|\[\g&lt;square&gt;*+\])*+)(\])[ ]?(\[)(.*?)(\])</string>
<string>(\!\[)((?&lt;square&gt;[^\[\]\\]|\\.|\[\g&lt;square&gt;*+\])*+)(\])[ ]?(\[)(.*?)(\])</string>
<key>name</key>
<string>meta.image.reference.markdown</string>
</dict>