Following the approach used in other syntax definitions, add support for defining the "syntax sync minlines=..." values for rst files in the users' ~/.vimrc files, to allow the users to adjust that value in case syntax highlighting stops working for some of the files they edit.
Signed-off-by: Dragan Simic <dsi...@manjaro.org> --- Notes: It seems that patches like this one should be submitted through the respective GitHub project pages. Though, I'm unable to use GitHub, so I'd appreciate if this patch could be picked up from the vim-dev mailing list by the respective project maintainer. runtime/syntax/rst.vim | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/runtime/syntax/rst.vim b/runtime/syntax/rst.vim index a90c90be21a2..b4f50f36f4a3 100644 --- a/runtime/syntax/rst.vim +++ b/runtime/syntax/rst.vim @@ -3,7 +3,7 @@ " Maintainer: Marshall Ward <marshall.w...@gmail.com> " Previous Maintainer: Nikolai Weibull <n...@bitwi.se> " Website: https://github.com/marshallward/vim-restructuredtext -" Latest Revision: 2020-03-31 +" Latest Revision: 2025-03-06 if exists("b:current_syntax") finish @@ -246,8 +246,7 @@ endfor " Enable top level spell checking syntax spell toplevel -" TODO: Use better syncing. -syn sync minlines=50 linebreaks=2 +exe "syn sync minlines=" . get(g:, 'rst_minlines', 50) . " linebreaks=2" hi def link rstTodo Todo hi def link rstComment Comment -- -- You received this message from the "vim_dev" maillist. Do not top-post! Type your reply below the text you are replying to. For more information, visit http://www.vim.org/maillist.php --- You received this message because you are subscribed to the Google Groups "vim_dev" group. To unsubscribe from this group and stop receiving emails from it, send an email to vim_dev+unsubscr...@googlegroups.com. To view this discussion visit https://groups.google.com/d/msgid/vim_dev/e8e879e15d0dba6195e6f42e52ac32d7001be6b6.1741282771.git.dsimic%40manjaro.org.