diff options
author | Thomas Vigouroux <thomas.vigouroux@protonmail.com> | 2022-07-18 14:21:40 +0200 |
---|---|---|
committer | Lewis Russell <lewis6991@gmail.com> | 2022-09-06 10:14:11 +0100 |
commit | 75adfefc85bcf0d62d2c0f51a951e6003b595cea (patch) | |
tree | 98e20f97a5c5ce818ade4f330bca45ca1d4d26bf /src/nvim/buffer_defs.h | |
parent | 05893aea391d91e159a41f03acc20049c7049510 (diff) | |
download | rneovim-75adfefc85bcf0d62d2c0f51a951e6003b595cea.tar.gz rneovim-75adfefc85bcf0d62d2c0f51a951e6003b595cea.tar.bz2 rneovim-75adfefc85bcf0d62d2c0f51a951e6003b595cea.zip |
feat(extmarks,ts,spell): full support for spelling
- Added 'spell' option to extmarks:
Extmarks with this set will have the region spellchecked.
- Added 'noplainbuffer' option to 'spelloptions':
This is used to tell Neovim not to spellcheck the buffer. The old
behaviour was to spell check the whole buffer unless :syntax was set.
- Added spelling support to the treesitter highlighter:
@spell captures in highlights.scm are used to define regions which
should be spell checked.
- Added support for navigating spell errors for extmarks:
Works for both ephemeral and static extmarks
- Added '_on_spell_nav' callback for decoration providers:
Since ephemeral callbacks are only drawn for the visible screen,
providers must implement this callback to instruct Neovim which
regions in the buffer need can be spell checked.
The callback takes a start position and an end position.
Note: this callback is subject to change hence the _ prefix.
- Added spell captures for built-in support languages
Co-authored-by: Lewis Russell <lewis6991@gmail.com>
Co-authored-by: Björn Linse <bjorn.linse@gmail.com>
Diffstat (limited to 'src/nvim/buffer_defs.h')
-rw-r--r-- | src/nvim/buffer_defs.h | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/nvim/buffer_defs.h b/src/nvim/buffer_defs.h index c26b18a7e7..a520f3c0e7 100644 --- a/src/nvim/buffer_defs.h +++ b/src/nvim/buffer_defs.h @@ -462,6 +462,9 @@ typedef struct { char *b_p_spf; // 'spellfile' char *b_p_spl; // 'spelllang' char *b_p_spo; // 'spelloptions' +#define SPO_CAMEL 0x1 +#define SPO_NPBUFFER 0x2 + unsigned b_p_spo_flags; // 'spelloptions' flags int b_cjk; // all CJK letters as OK uint8_t b_syn_chartab[32]; // syntax iskeyword option char *b_syn_isk; // iskeyword option |