diff --git a/runtime/doc/syntax.txt b/runtime/doc/syntax.txt index 8fba2bc032..baafd8c00a 100644 --- a/runtime/doc/syntax.txt +++ b/runtime/doc/syntax.txt @@ -2892,6 +2892,9 @@ To enable folding of sections: > Note that folding can cause performance issues on some platforms. +The minimum line syntax sync is set to 50. To modify this number: > + let rst_minlines = 100 + REXX *ft-rexx-syntax* diff --git a/runtime/syntax/rst.vim b/runtime/syntax/rst.vim index c43bda5892..34e43932b6 100644 --- a/runtime/syntax/rst.vim +++ b/runtime/syntax/rst.vim @@ -246,11 +246,11 @@ for s:filetype in keys(g:rst_syntax_code_list) unlet! prior_isk 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