aboutsummaryrefslogtreecommitdiff
path: root/src/nvim/bufhl_defs.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/nvim/bufhl_defs.h')
-rw-r--r--src/nvim/bufhl_defs.h9
1 files changed, 9 insertions, 0 deletions
diff --git a/src/nvim/bufhl_defs.h b/src/nvim/bufhl_defs.h
index e47bb2a238..0667a82a62 100644
--- a/src/nvim/bufhl_defs.h
+++ b/src/nvim/bufhl_defs.h
@@ -3,6 +3,7 @@
#include "nvim/pos.h"
#include "nvim/lib/kvec.h"
+#include "nvim/lib/kbtree.h"
// bufhl: buffer specific highlighting
struct bufhl_hl_item
@@ -17,9 +18,17 @@ typedef struct bufhl_hl_item bufhl_hl_item_T;
typedef kvec_t(struct bufhl_hl_item) bufhl_vec_T;
typedef struct {
+ linenr_T line;
+ bufhl_vec_T items;
+} BufhlLine;
+
+typedef struct {
bufhl_vec_T entries;
int current;
colnr_T valid_to;
} bufhl_lineinfo_T;
+#define BUFHL_CMP(a, b) (((b)->line - (a)->line))
+KBTREE_INIT(bufhl, BufhlLine *, BUFHL_CMP)
+typedef kbtree_t(bufhl) bufhl_info_T;
#endif // NVIM_BUFHL_DEFS_H