Skip to content

runtime(tex): Update b:match_words#20108

Draft
dkearns wants to merge 1 commit into
vim:masterfrom
dkearns:runtime-tex-update-match_words
Draft

runtime(tex): Update b:match_words#20108
dkearns wants to merge 1 commit into
vim:masterfrom
dkearns:runtime-tex-update-match_words

Conversation

@dkearns
Copy link
Copy Markdown
Contributor

@dkearns dkearns commented May 1, 2026

@Konfekt it looks like \(, \[, \{ should be bumped up to ftplugin/plaintex.vim?

Signed-off-by: Enno Nagel <ennonagel+vim@gmail.com>
Signed-off-by: Doug Kearns <dougkearns@gmail.com>
Comment thread runtime/ftplugin/tex.vim
" TODO: Fix \, bug in matchit, https://github.com/vim/vim/issues/1052#issuecomment-4140499396
let b:match_words .= '\%(^\|[ (/]\)\@<=\\(' . ':' . '\\)\%($\|[ )/.;\:?!\-]\)\@=' .
\ ',' . '\%(^\|[ (/]\)\@<=\\\[' . ':' . '\\\]\%($\|[ )/.;\:?!\-]\)\@=' .
\ ',' . '\%(^\|[ (/]\)\@<=\$[^$ ]' . ':' . '[^$ ]\@<=\$\%($\|[ )/.;\:?!\-]\)\@=' .
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@dkearns only these two lines for $ and $$ would belong to plaintex which uses them as math delimiters, the others are used by Latex and better be kept in tex.vim

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants