summaryrefslogtreecommitdiff
path: root/src/structs.h
diff options
context:
space:
mode:
authorBram Moolenaar <Bram@vim.org>2020-05-31 19:48:53 +0200
committerBram Moolenaar <Bram@vim.org>2020-05-31 19:48:53 +0200
commite35a52aee718c881bdfa69a47a1068df6ab6c60a (patch)
tree2b0b7da0fa124d685a6885e2b3476ffd8021e66c /src/structs.h
parentd881b516da0184052d2f9d33c3f72c5c014316bd (diff)
downloadvim-git-e35a52aee718c881bdfa69a47a1068df6ab6c60a.tar.gz
patch 8.2.0865: syntax foldlevel is taken from the start of the linev8.2.0865
Problem: Syntax foldlevel is taken from the start of the line. Solution: Add ":syn foldlevel" to be able to use the minimal foldlevel in the line. (Brad King, closes #6087)
Diffstat (limited to 'src/structs.h')
-rw-r--r--src/structs.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/structs.h b/src/structs.h
index 9968e9205..8fb14d759 100644
--- a/src/structs.h
+++ b/src/structs.h
@@ -2266,6 +2266,10 @@ typedef struct
#define SYNSPL_TOP 1 // spell check toplevel text
#define SYNSPL_NOTOP 2 // don't spell check toplevel text
+// values for b_syn_foldlevel: how to compute foldlevel on a line
+#define SYNFLD_START 0 // use level of item at start of line
+#define SYNFLD_MINIMUM 1 // use lowest local minimum level on line
+
// avoid #ifdefs for when b_spell is not available
#ifdef FEAT_SPELL
# define B_SPELL(buf) ((buf)->b_spell)
@@ -2360,6 +2364,7 @@ typedef struct {
int b_syn_slow; // TRUE when 'redrawtime' reached
# endif
int b_syn_ic; // ignore case for :syn cmds
+ int b_syn_foldlevel; // how to compute foldlevel on a line
int b_syn_spell; // SYNSPL_ values
garray_T b_syn_patterns; // table for syntax patterns
garray_T b_syn_clusters; // table for syntax clusters