Commit Graph

61 Commits

Author SHA1 Message Date
Tim Pope
296eeaa887 Support tilde code blocks
Also ensure the end marker has the same number of delimiter characters
as the start marker.

Closes https://github.com/tpope/vim-markdown/issues/156
2020-02-21 00:25:51 -05:00
Tim Pope
6c4c60fbaa Also don't let HTML and dependent syntaxes change 'foldmethod'
References https://github.com/tpope/vim-markdown/issues/154
2020-01-30 12:56:09 -05:00
Tim Pope
719b046bbe Don't let fenced language syntaxes change 'foldmethod'
Closes https://github.com/tpope/vim-markdown/issues/154
2020-01-30 12:45:09 -05:00
Tim Pope
4e25b2f606 Vim 8.2.0141 2020-01-30 11:50:49 -05:00
Tim Pope
e875717243 Fix closing italics
Closes https://github.com/tpope/vim-markdown/issues/151
2019-12-12 13:55:26 -05:00
Tim Pope
a273e6d1f3 Vim 8.2 2019-12-12 13:54:51 -05:00
Tim Pope
9c2133fef0 Skip escaped bold/italics closer
Closes https://github.com/tpope/vim-markdown/issues/102
2019-12-02 08:47:20 -05:00
Igor Mikushkin
8a76c845de Github flavored parsing of underscores 2019-12-01 07:42:25 -05:00
Tim Pope
06a62df8a5 Restrict HTML highlighting when nesting
Closes https://github.com/tpope/vim-markdown/issues/148
2019-11-23 16:02:45 -05:00
Tim Pope
5363a4d803 Allow one level of nested brackets
Closes https://github.com/tpope/vim-markdown/issues/129
2019-10-23 03:03:09 -04:00
Greg Anders
64689dfeae Support pandoc syntax for fenced code blocks 2019-10-10 18:10:49 -04:00
Thomas Faingnaert
c043a93c84 Conceal code blocks 2019-07-28 19:37:25 -04:00
Alex Griffin
8cd41796fd Separate highlight groups for each heading level
Closes tpope#123.
2017-10-17 20:30:01 -04:00
Tim Pope
a7dbc31456 Three or more backticks, not two or more 2017-05-08 11:37:43 -04:00
Tim Pope
44822aa3c6 Allow fenced language names to contain punctuation
Closes https://github.com/tpope/vim-markdown/issues/116
2017-05-08 11:36:12 -04:00
Linda_pp
0b92a7d4cb Customizable minlines with g:markdown_minlines (#115) 2017-04-11 23:06:07 -04:00
Addison Bean
3c2215bfed Fix spell check on bold and italic text (#101)
Closes #100.
2016-07-01 17:15:47 -04:00
Rob Hurring
5c21f16771 Allow toggling of syntax concealing (#99)
Add `let g:markdown_syntax_conceal = 0` to your vimrc
2016-05-08 19:57:37 -04:00
tyru
63074a52ad Avoid E403 error on :syn-include
Example .vimrc:

        let g:markdown_fenced_languages = ['vim', 'viml=vim']
        syntax on

causes

        "/tmp/test.mkd" 6L, 98C
        Error detected while processing /usr/share/vim/vim74/syntax/vim.vim:
        line  777:
        E403: syntax sync: line continuations pattern specified twice
        E403: syntax sync: line continuations pattern specified twice

Example "test.mkd" file:

        ```vim
        echo 'hi'
        ```
2016-01-23 02:09:00 +09:00
afc163
b938671300 Support more backtick
like

````
code
````
2015-12-04 16:02:12 +08:00
Tim Pope
6eac9ffb58 Revert "Improve fenced code block matching"
This reverts commit aff85c6411.

Closes https://github.com/tpope/vim-markdown/issues/83
2015-10-12 13:53:26 -04:00
Kevin Locke
aff85c6411 Improve fenced code block matching
The previous fenced code block matching did not support the syntax used
by [Kramdown][1] or fully support the syntax described in
[CommonMark][2].  The differences are:

* Kramdown requires \~ instead of \` in fences (CommonMark permits \~)
* Both permit code fences to have more than 3 \~ or \` characters
* Both require the closing fence to have as many chars as the opening
* Both permit the closing fence to have extra fence chars
* CommonMark explicitly forbids \` in the fence info string

This is likely the case with other Markdown variants, but these are the
only two that I have considered when authoring this commit.

This commit implements all of the above mentioned changes.  The change
is mostly straight-forward.  The only exception is that the end matching
is a little subtle since one of `\z2` and `\z3` will be empty, using the
more natural expression `\z2*\|\z3*` can hang the regex matcher.  The
`\%(\z2\z3)*` expression is a bit less obvious but works reliably.

Note that I did not include any changes relating to the Pandoc syntax
mentioned in #65 and #74.  If this syntax is desired, I can adjust this
commit to include it.

[1]:  http://kramdown.gettalong.org/syntax.html#fenced-code-blocks
[2]:  http://spec.commonmark.org/0.22/#code-fence

Signed-off-by: Kevin Locke <kevin@kevinlocke.name>
2015-10-02 22:12:34 -07:00
Allen Hubbe
188d816314 Add escape support for angle braces 2015-07-17 23:49:00 -04:00
Tim Pope
409c37b205 Conceal bold and italic markers
References #9.
2014-07-11 13:35:48 -04:00
Sencer Selcuk
cb2b885214 Footnote doesn't have to be at the line end. 2014-06-19 17:30:13 -04:00
Sencer Selcuk
db5c79f7c0 Allow multi-char footnote labels. 2014-06-19 17:13:36 -04:00
Paul Jolly
ede001b33d Footnote support 2014-02-24 13:10:20 +00:00
Tim Pope
61deff1362 Allow link nesting
Closes #58.
2014-01-01 11:48:03 -05:00
Tim Pope
3fb5b260e1 Merge upstream changes 2013-12-16 20:55:46 -05:00
Drew Neil
a126974366 Add 'Last change: 2013 May 30' to headers 2013-11-16 16:48:16 +00:00
Andrew Radev
55b49cad42 Allow spaces after ```
With a fenced code block with a language, it's legal to put spaces
between the fence and the language name.
2013-06-24 11:00:29 +02:00
Tim Pope
451eefb9b2 Merge pull request #41 from cemerick/master
Highlight italicized regions within bold regions
2013-05-27 11:28:32 -07:00
Chas Emerick
697edbe7ca Highlight italicized regions within bold regions 2013-05-14 07:50:17 -04:00
David J. Hamilton
de106cb725 Clear main_syntax if we set it.
This prevents conflicts with other syntaxes that use `main_syntax`, like
vim-javascript.
2013-05-02 12:08:46 -07:00
Tim Pope
ec0abb3064 Support blank lines in block quotes 2013-03-05 13:49:30 -05:00
Tim Pope
90fc7fc593 Fix highlighting HTML entities at start of line 2013-03-05 13:46:53 -05:00
Tim Pope
e8fa4faf82 Support indented fenced code blocks 2013-03-01 22:44:23 -05:00
Hinrik Örn Sigurðsson
5ed43c22bc Require space after ordered list marker 2013-01-27 15:22:31 -05:00
Hinrik Örn Sigurðsson
242dda3f01 Allow automatic links in headings 2013-01-25 19:12:36 -05:00
Bryan Richter
10cf9687d2 A more liberal markdownValid 2013-01-21 17:30:43 +00:00
Tim Pope
9407dae660 Really fix options after ```language 2012-10-12 18:20:48 -04:00
Tim Pope
ecafbe32a8 Fix ```language with more junk on the same line 2012-10-12 18:03:18 -04:00
Tim Pope
b2697b0adf Highlight GitHub style fenced code blocks
One needs to opt-in to this by specifying which file types should be
highlighted:

    let g:markdown_github_languages = ['ruby', 'erb=eruby']

This may not work for all file types.

Closes #17.
2012-10-12 17:58:09 -04:00
Tim Pope
7b747d0aa4 Improve tab handling
Closes #18.
2012-07-08 04:06:40 -04:00
Tim Pope
9a21f7a6bc Ignore options after ```filetype
Closes #22.
2012-06-28 23:31:35 -04:00
Tim Pope
3a99157473 Flag internal underscores in headings 2012-04-01 22:55:05 -04:00
Emil Loer
5a70519e48 Fix performance issue with detecting setext-style headers 2011-11-23 00:15:00 -05:00
Tim Pope
ae3a2653f8 Loosen GitHub code block pattern 2011-08-26 16:09:31 -04:00
Tim Pope
ac0d7dee84 Highlight word underscores as errors 2011-08-26 03:31:45 -04:00
Tim Pope
8f7b69b52e Add highlighting for GitHub style code blocks 2011-08-26 03:26:19 -04:00