Commit Graph

18618 Commits

Author SHA1 Message Date
Björn Linse
25a879dfa2 feat(decorations): deprecate nvim_buf_set_virtual_text
Full virt_text functionality is provided by nvim_buf_set_extmark
2021-07-29 20:36:12 +02:00
Björn Linse
a4d81a8002 refactor(decorations): merge the two different code paths for virt_text
test(bufhl): CHANGE of tested behaviour (inb4 a proper priority mechanism)
test(decoration): change of test; previous behavior was buggy (ghost
buffer text)
2021-07-29 20:34:42 +02:00
Björn Linse
1495d36d63 feat(decorations): allow more than one stacked highlight in a virt_text 2021-07-29 20:34:20 +02:00
Gregory Anders
3521bf7672
feat(lsp): implement vim.lsp.diagnostic.redraw() (#15203)
Add a new function to redraw diagnostics from the current diagnostic
cache, without receiving a "publishDiagnostics" message from the server.
This is already being done in two places in the Lua stdlib, so this
function unifies that functionality in addition to providing it to third
party plugins.

An example use case for this could be a command or key-binding for
toggling diagnostics virtual text. The virtual text configuration option
can be toggled using `vim.lsp.with` followed by
`vim.lsp.diagnostic.redraw()` to immediately redraw the diagnostics
with the updated setting.
2021-07-29 09:02:17 -07:00
Thomas Vigouroux
3b6d95b5f6
Merge pull request #15213 from zeertzjq/vim-8.2.3236
vim-patch:8.2.3236: mode() does not indicate using CTRL-O in Select mode
2021-07-29 17:03:12 +02:00
Christian Clason
143a920de9
chore: fix lsp bug issue template
correct description for expected behavior
2021-07-29 16:35:02 +02:00
Christian Clason
1d3aaae15c
chore: fix bug issue template form
description for "expected behavior" was wrongly attached to "actual behavior"
2021-07-29 16:17:58 +02:00
Björn Linse
98c4b2cf62
Merge pull request #15215 from bfredl/fix_15212
fix(decorations): crash when :bdelete (extmark_free_all) after clear_namespace
2021-07-29 14:25:02 +02:00
Björn Linse
cd353aa824 fix(decorations): crash when :bdelete (extmark_free_all) after clear_namespace
fixes #15212
2021-07-29 12:59:56 +02:00
zeertzjq
04ba81ddba vim-patch:8.2.3236: mode() does not indicate using CTRL-O in Select mode
Problem:    mode() does not indicate using CTRL-O in Select mode.
Solution:   Use "vs" and similar. (closes vim/vim#8640)
eaf3f36168
2021-07-29 07:47:17 +08:00
Christian Clason
ac5139eae4
ci(labeler): adapt to new label names 2021-07-28 17:29:27 +02:00
Gregory Anders
cab90f2ef1 fixup! fix(highlight): remove syncolor.vim 2021-07-28 09:11:07 -06:00
dundargoc
6c08af083d
ci: label PRs only the first time they're opened (#15209)
instead of on every change -- including removing erroneous labels
2021-07-28 11:30:08 +02:00
Christian Clason
701c21480e
ci(labeler): update label format 2021-07-28 10:10:45 +02:00
Gregory Anders
9190addf1f fixup! fix(highlight): remove syncolor.vim 2021-07-27 16:00:53 -06:00
Gregory Anders
d3bc61b31d fixup! fix(highlight): remove syncolor.vim 2021-07-27 14:14:42 -06:00
Gregory Anders
9afa0d25a6 fix(highlight): remove syncolor.vim
Remove syncolor.vim in favor of defining the default highlight groups
directly in `init_highlight`. This approach provides a number of
advantages:

1. The highlights are always defined, regardless of whether or not the
   syntax regex engine is enabled.
2. Redundant sourcing of syntax files is eliminated (syncolor.vim was
   often sourced multiple times based on how the user's colorscheme file
   was written).
3. The syntax highlighting regex engine and the highlight groups
   themselves are more fully decoupled.
4. Removal of the confusing `:syntax on` / `:syntax enable` dichotomy
   (they now both do the same thing).

This approach also correctly solves a number of bugs related to
highlighting (#15176, #12573, #15205).
2021-07-27 14:14:30 -06:00
Thomas Vigouroux
c642f3ac27
Merge pull request #15142 from neovim/marvim/api-doc-update/master
docs: regenerate
2021-07-27 11:28:04 +02:00
marvim
86baf582b8 docs: regenerate 2021-07-26 18:48:46 +00:00
Björn Linse
c818d8df34
Merge pull request #15197 from dundargoc/refactor/a-song-of-true-and-false/global-variables
refactor: replace TRUE/FALSE with true/false
2021-07-26 20:41:54 +02:00
Gregory Anders
3e00d4f01c
feat(lsp): make list handlers configurable (#15199)
The handlers for textDocument/references, textDocument/documentSymbol,
and workspace/symbol open their results in the quickfix list by default
and are not configurable. They are also incompatible with `vim.lsp.with`
as they do not accept a configuration parameter.

Add a `config` parameter to the handler for these three messages which
allows them to be configured with `vim.lsp.with`. Additionally, add a
new configuration option 'loclist' that, when true, causes these
handlers to open their results in the location list rather than the
quickfix list.
2021-07-26 11:39:50 -07:00
Thomas Vigouroux
b8813bacfe
Merge pull request #15090 from kraftwerk28/master
docs: fix typo in treesitter.txt
2021-07-26 20:38:11 +02:00
Thomas Vigouroux
ec7881bbfd
Merge pull request #15180 from gpanders/xcalloc
fix: fix incorrect call sites of xcalloc
2021-07-26 20:30:10 +02:00
Thomas Vigouroux
0e22a40b6d
Merge pull request #15191 from vigoux/ts-docs
docs(ts): add documentation for listing fns
2021-07-26 18:48:15 +02:00
Christian Clason
1637622db9
chore: remove checkbox from issue template
Checkboxes trigger "task lists", which add noise.
2021-07-26 17:31:27 +02:00
Dundar Göc
dfd9d861dc refactor: replace TRUE/FALSE with true/false
Focus is on global variables.
2021-07-26 17:12:35 +02:00
Björn Linse
7b520cca3a
Merge pull request #15151 from dundargoc/refactor/true-and-false-macro
refactor: replace TRUE/FALSE macros with C99 true/false
2021-07-26 10:25:08 +02:00
Dundar Göc
11dcf15682 refactor: replace TRUE/FALSE macros with C99 true/false 2021-07-25 21:51:50 +02:00
Thomas Vigouroux
5c42e2a87f
docs(ts): add documentation for listing fns 2021-07-25 20:52:05 +02:00
Björn Linse
192adfe99f
Merge pull request #14311 from matveyt/nomode_ce
refactor(state): Remove EXMODE_NORMAL
2021-07-25 19:35:23 +02:00
dundargoc
f15c745502
chore: PVS/V751: ignore warning #15153
There's already an ignore directive but it's placed on the wrong line.
This commit should correct it.
2021-07-25 10:19:56 -07:00
Rishabh Dwivedi
53f70bb183
chore: added ccls-cache in .gitignore (#15175) 2021-07-25 19:12:07 +02:00
Thomas Vigouroux
3a34f59ae8
Merge pull request #14347 from theHamsta/list_directives
treesitter: add query.list_directives
2021-07-25 16:49:22 +02:00
dundargoc
bebca7bbeb
chore: update LSP bug report with Github issue forms (#15159) 2021-07-25 16:07:20 +02:00
dundargoc
1aef6297b3
chore: update feature request template by using Github issue forms. (#15158) 2021-07-25 16:06:19 +02:00
dundargoc
e5f3abfd17
chore: update bug report template by using Github's new issue forms (#15152) 2021-07-25 16:05:11 +02:00
Björn Linse
a8f00e39ba
Merge pull request #15178 from gpanders/master
fix: source syncolors.vim after startup scripts
2021-07-25 15:36:04 +02:00
Gregory Anders
3fd4f2f611 fix: fix incorrect call sites of xcalloc
The number of elements comes first and the size of each element second.
2021-07-24 15:52:14 -06:00
Stephan Seitz
289c153d1f doc: group documentation of predicates and directives 2021-07-24 20:57:45 +02:00
Stephan Seitz
b2a9afef6d treesitter: add query.list_directives 2021-07-24 20:57:45 +02:00
Gregory Anders
860aedd06b fix: source syncolors.vim after startup scripts
This fixes an issue introduced in #14771 (fix: source syncolors.vim
before startup scripts) that affected highlights for users who set
'background' to light in their startup script. Because syncolor.vim
checks for the value of &background, it was always setting up the 'dark'
background colors, which looked wrong for users using light backgrounds.

The primary benefit of #14771 is that it decoupled highlighting from the
syntax engine. This is useful for e.g. treesitter, which still makes use
of highlights even if the syntax engine is disabled. For this reason, it
is still worthwhile to source syncolor.vim separately from synload.vim,
which #14771 accomplishes. However, we should still source syncolor.vim
after the user startup scripts, to ensure that we are respecting the
options the user sets.

Another corollary benefit is that this reduces some redundancy in
highlight definitions, since we now only source syncolors.vim if the
user did not already enable a colorscheme.
2021-07-24 10:28:16 -06:00
Björn Linse
46009499af
Merge pull request #15169 from bfredl/freebsdfail
fix(ci): disable broken test on openbsd also on freebsd
2021-07-24 13:18:38 +02:00
Björn Linse
13db912e51 fix(ci): lower timeout to 45 minutes (from default 360 mins) 2021-07-24 10:23:15 +02:00
Björn Linse
a3e2636afd fix(ci): disable broken test on openbsd on all CI due to resource constraints 2021-07-23 19:35:32 +02:00
matveyt
8ce0929418 Remove EXMODE_NORMAL 2021-07-23 18:08:40 +02:00
Björn Linse
754ac5a834
Merge pull request #15114 from theHamsta/treesitter-hl-priority
feat(treesitter): allow to set highlight priority for queries
2021-07-23 17:56:16 +02:00
Stephan Seitz
5ea6cc1d75 docs(tree-sitter): document highlight priority 2021-07-22 21:38:57 +02:00
Stephan Seitz
242608e669 feat(treesitter): allow to set highlight priority for queries 2021-07-22 21:38:57 +02:00
Marc Jakobi
a8c3d50fad
lsp: add vim.lsp.diagnostic.set_qflist() function (#14831)
* Add vim.lsp.diagnostic.set_qflist() function
* replaces opts.open_loclist with unified opts.open
2021-07-22 08:48:28 -07:00
Björn Linse
ea35584bac
Merge pull request #14771 from gpanders/colorscheme
fix: source syncolors.vim before startup scripts
2021-07-22 14:10:56 +02:00