vim-pandoc / vim-pandoc-legacy

[UNSUPPORTED/use vim-pandoc/vim-pandoc] vim bundle for pandoc users
143 stars 23 forks source link

Over Match the the char '-' when it is used as separated line or table line #104

Closed zcchen closed 10 years ago

zcchen commented 10 years ago

In pandoc syntax, there are few using ways for char '-'. '--' means en-dash '---' means em-dash '--------'(more than 3) means separated line '+--------+-----+'(maybe also ':' or '|' here) means the table line.

The nowadays vim-pandoc plugins will match the line syntax as many em-dashes together. It makes the text ugly.

Example as below:

2012 -- 2013, It works perfect here. --- em-dash, I need em-dash. It is OK here.


separated line. It looks shorter here.

+-------+------+ | one | two | +-------+------+ | three | four | +-------+------+ The table above looks ugly. :-(

fmoralesc commented 10 years ago

We just finished working on table support at vim-pandoc-syntax, which should help in this case and is the preferred syntax file (the syntax file here at vim-pandoc lags behind it). Also, you can configure it to disable conceals for horizontal rules or dashes, which you could prefer.

For example, this is what your example text looks like by disabling hrules concealment:

captura de pantalla de 2014-02-02 11 58 05

:let g:pandoc_syntax_dont_use_conceal_for_rules=["hrule"]