]> git.ipfire.org Git - thirdparty/vim.git/commitdiff
runtime(html): update syntax script to sync by 250 minlines by default
authorChristian Brabandt <cb@256bit.org>
Tue, 30 Jul 2024 18:19:15 +0000 (20:19 +0200)
committerChristian Brabandt <cb@256bit.org>
Tue, 30 Jul 2024 18:22:20 +0000 (20:22 +0200)
closes: #14071

Signed-off-by: Christian Brabandt <cb@256bit.org>
runtime/doc/syntax.txt
runtime/syntax/html.vim

index 2f8d9505c4af01f39d01387eca73f707955ca39f..9449b7577457bb7176adf845d3286c1e34f7b0c5 100644 (file)
@@ -1,4 +1,4 @@
-*syntax.txt*   For Vim version 9.1.  Last change: 2024 Jul 25
+*syntax.txt*   For Vim version 9.1.  Last change: 2024 Jul 30
 
 
                  VIM REFERENCE MANUAL    by Bram Moolenaar
@@ -1908,6 +1908,10 @@ You can also disable this rendering by adding the following line to your
 vimrc file: >
        :let html_no_rendering=1
 
+By default Vim synchronises the syntax to 250 lines before the first displayed
+line.  This can be configured using: >
+       :let html_minlines = 500
+<
 HTML comments are rather special (see an HTML reference document for the
 details), and the syntax coloring scheme will highlight all errors.
 However, if you prefer to use the wrong style (starts with <!-- and
index d067dde83c051b5ab192a1896f9b504012daaf36..ca7c7f1cddaa955c68e2751e7b2ceaf062b6aaf1 100644 (file)
@@ -4,6 +4,7 @@
 " Previous Maintainers: Jorge Maldonado Ventura <jorgesumle@freakspot.net>
 "                      Claudio Fleiner <claudio@fleiner.com>
 " Last Change:         2023 Nov 28
+" 2024 Jul 30 by Vim Project: increase syn-sync-minlines to 250
 
 " See :help html.vim for some comments and a description of the options
 
@@ -320,7 +321,7 @@ if main_syntax == "html"
   syn sync match htmlHighlight groupthere NONE "<[/a-zA-Z]"
   syn sync match htmlHighlight groupthere javaScript "<script"
   syn sync match htmlHighlightSkip "^.*['\"].*$"
-  syn sync minlines=10
+  exe "syn sync minlines=" . get(g:, 'html_minlines', 250)
 endif
 
 " Folding