| Commit message (Collapse) | Author | Age |
... | |
|
|
|
|
|
|
|
| |
Problem: No test for what patch 9.1.1152 fixes.
Solution: Add a test (zeertzjq).
closes: vim/vim#16742
https://github.com/vim/vim/commit/4be1ab80befd78a80a05c2e66aeff58113832f46
|
|
|
|
|
|
|
|
|
|
|
| |
Problem: Mode message not cleared after :silent message
(after 9.0.1634).
Solution: Don't reset mode_displayed when the message is empty.
(zeertzjq)
fixes: neovim/neovim#32641
closes: vim/vim#16744
https://github.com/vim/vim/commit/fce1fa5b618458f6f10028faadc9a9ddc227fe76
|
|
|
|
|
|
|
|
|
| |
Problem: Wrong script context for option set by function defined by
nvim_exec2 in a Lua script.
Solution: Call nlua_set_sctx() after adding SOURCING_LNUM and always set
sc_lnum for a Lua script.
This is a bug discovered when testing #28486. Not sure if this actually
happens in practice, but it's easy to fix and required for #28486.
|
|
|
| |
Off-by-one error in storing last line number for a logical line.
|
|
|
|
|
|
|
|
|
|
|
| |
Problem:
popup floating window is closed and recreated for each item selection,
this is a bit wasteful.
Solution:
- Hide the preview win (instead of closing it) when the menu is still displayed:
1. When selected_item is -1.
2. When switching from an item with an "info" field to one without.
- When pum is undisplayed it is still closed.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Problem:
Descriptions are somewhat vague. nvim_set_current_line modifies contents
but nvim_set_current_buf does not, etc.
Solution:
- Make it clear that these functions accept or return a winid/tabid by
linking to that concept in help.
- Only these few files use the term "handles", so replace them with the
more conventional terminology.
- Add a new help section for tab-ID. This concept is unique to neovim
because vim exposes tabnr, but not tab handles. This section is
modelled after `:h winid`.
|
|
|
| |
The code above have already set sc_lnum to 0.
|
|
|
|
|
|
|
| |
(#32642)
Problem: f58e7d5f passed `&botline` to `plines_win_full()`, (probably)
assuming it would be set to the first line of the fold.
Solution: Reinstate call to `hasFolding()` to do so.
|
| |
|
| |
|
|\
| |
| | |
vim-patch:9.1.{1151,1152}
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Problem: Patch v9.1.1151 causes problems
Solution: partially revert it (John Marriott)
closes: vim/vim#16736
https://github.com/vim/vim/commit/18bacc811c30ba26405cadbeb79d9013d9885bb5
Co-authored-by: John Marriott <basilisk@internode.on.net>
|
|/
|
|
|
|
|
|
|
|
|
|
|
| |
Problem: too many strlen() calls in getchar.c
Solution: store last inserted and recorded lengths,
add functions to retrieve those and use those
functions (John Marriott)
closes: vim/vim#16720
https://github.com/vim/vim/commit/d3c4b7e9461f90bad7a671c1221d65def9cccc89
Co-authored-by: John Marriott <basilisk@internode.on.net>
|
| |
|
|\ |
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Problem:
Test sometimes fails on bsd (cirrus ci):
test/functional/ex_cmds/swapfile_preserve_recover_spec.lua:589: retry() attempts: 464
test/functional/ex_cmds/swapfile_preserve_recover_spec.lua:590: Expected objects to be the same.
Passed in:
(table: 0x0d5f1aa44070) {
[1] = ''
*[2] = ''
[3] = '[Process exited 1]' }
Expected:
(table: 0x0d5ea3eb8718) {
[1] = ''
*[2] = '[Process exited 1]'
[3] = '' }
stack traceback:
test/testutil.lua:104: in function 'retry'
test/functional/ex_cmds/swapfile_preserve_recover_spec.lua:589: in function <test/functional/ex_cmds/swapfile_preserve_recover_spec.lua:556>
Solution:
Filter out empty items to avoid irrelevant redraw-timing assumptions.
|
|/
|
|
|
|
|
|
|
|
|
|
|
| |
Problem:
Indenting text is a common task in plugins/scripts for
presentation/formatting, yet vim has no way of doing it (especially
"dedent", and especially non-buffer text).
Solution:
Introduce `vim.text.indent()`. It sets the *exact* indentation because
that's a more difficult (and thus more useful) task than merely
"increasing the current indent" (which is somewhat easy with a `gsub()`
one-liner).
|
|
|
|
|
|
|
|
|
|
|
| |
Problem: read/write shada function logic was skipped entirely if it was
detected the shadafile option was set to 'NONE'.
Solution: The filename is now always resolved. When the shadafile option
is set to 'NONE' AND no filename was passed, the filename resolves to an
empty string, which causes the read/write functions to return.
Regardless of whether the option is set to 'NONE', when a filename is
explicitly passed, it gets resolved and the read/write logic is
accessed.
|
|
|
|
|
|
|
|
|
|
|
| |
- Move all generator Lua scripts to the `src/gen/`
- Add a `.luarc.json` to `src/gen/`
- Add a `preload.lua` to `src/gen/`
- Add `src` to `package.path` so it aligns with `.luarc.json'
- Fix all `require` statements in `src/gen/` so they are consistent:
- `require('scripts.foo')` -> `require('gen.foo')`
- `require('src.nvim.options')` -> `require('nvim.options')`
- `require('api.dispatch_deprecated')` -> `require('nvim.api.dispatch_deprecated')`
|
|
|
|
|
|
|
|
|
|
| |
Problem:
Generated Lua API bindings may have trailing spaces (e.g. nvim_set_hl).
Solution:
Add leading spaces only if arg_free_code is non-empty.
Also:
- Remove an unnecessary string.format() in write_shifted_output() args.
- Fix incorrect indent for the nlua_push_keydict() below.
|
|\
| |
| | |
fix(vim_snprintf): special-case handling of binary format
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
A binary format spec always expects a corresponding unsigned long long
value. However, that explicit handling didn't get included when porting
the code from Vim, so binary format spec was falling through to the
"unsigned" and "length_modifier = NUL" portion of the code:
} else {
// unsigned
switch (length_modifier) {
case NUL:
uarg = (tvs
? (unsigned)tv_nr(tvs, &arg_idx)
: (skip_to_arg(ap_types, ap_start, &ap, &arg_idx,
&arg_cur, fmt),
va_arg(ap, unsigned)));
break;
This incorrectly read an "unsigned" value from an "unsigned long long"
variable, which would produce incorrect results on certain platforms.
|
| |
| |
| |
| | |
Sync with commit https://github.com/openresty/lua-cjson/commit/91ca29db9a4a4fd0eedaebcd5d5f3ba2ace5ae63
|
| | |
|
|/ |
|
| |
|
| |
|
|\
| |
| | |
vim-patch: improve &keywordprg in Vim ftplugin
|
| |
| |
| |
| |
| |
| |
| |
| | |
closes: vim/vim#16729
https://github.com/vim/vim/commit/580e457a2a5fa63b9be0bf5f2c81434e157bcc0a
Co-authored-by: Konfekt <Konfekt@users.noreply.github.com>
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
- let keywordprg in vim filetype handle context-sensitive help calls by
detecting the syntax group of the word under the cursor
- reformat whitespace
- add modeline
related: vim/vim#16677
closes: vim/vim#16680
https://github.com/vim/vim/commit/094494bf2eef8d788944b2b00b3361feb545d3ae
Co-authored-by: Konfekt <Konfekt@users.noreply.github.com>
Co-authored-by: Andrew Radev <andrey.radev@gmail.com>
Co-authored-by: "D. Ben Knoble" <ben.knoble+github@gmail.com>
Co-authored-by: Gary Johnson <garyjohn@spocom.com>
Co-authored-by: Tim Pope <code@tpope.net>
Co-authored-by: Doug Kearns <dougkearns@gmail.com>
Co-authored-by: Christian Brabandt <cb@256bit.org>
|
|/
|
|
|
|
|
|
| |
Problem: When setting an option, mapping etc. from Lua without -V1, the
script ID is set to SID_LUA even if there already is a script
ID assigned by :source.
Solution: Don't set script ID to SID_LUA if it is already a Lua script.
Also add _editor.lua to ignorelist to make script context more
useful when using vim.cmd().
|
|
|
|
| |
Problem: Cursor row calculation does not take into account concealed lines.
Solution: Break the loop when the next calculated line is concealed.
|
| |
|
| |
|
|
|
|
|
|
|
|
| |
Problem: Height of a (markdown) `vim.lsp.util.open_floating_preview()`
window can be reduced to account for concealed lines (after #31324).
Solution: Set the window height to the text height of the preview window.
Set 'concealcursor' to avoid unconcealing the cursorline when
entering the hover window.
|
|
|
|
|
|
|
|
| |
TSHighlighter now places marks for conceal_lines metadata. A new
internal decor provider callback _on_conceal_line was added that
instructs the highlighter to place conceal_lines marks whenever the
editor needs to know whether a line is concealed. The bundled markdown
queries use conceal_lines metadata to conceal code block fence lines.
|
|
|
|
| |
Implement an extmark property that conceals lines vertically.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Problem: filetype: m17ndb files are not detected
Solution: detect m17ndb files as m17ndb filetype,
include filetype, syntax and indent files for the
new filetype (David Mandelberg).
References:
https://www.nongnu.org/m17n/manual-en/m17nDBFormat.html describes the
format. https://git.savannah.nongnu.org/cgit/m17n/m17n-db.git/tree/ has
examples of the files.
closes: vim/vim#16696
https://github.com/vim/vim/commit/ed7d8e55ac232758fc14fd132994b4a09b19350b
Also adjust the xkb parent pattern according to dev_vimpatch.txt.
Co-authored-by: David Mandelberg <david@mandelberg.org>
|
|
|
|
|
| |
* refactor: rewrite test without trailing whitespace
* test: combined injection tests
|
|
|
|
|
|
|
|
|
|
|
|
| |
line (#32625)
Problem: When expanding omni completion items with newlines (e.g.
`then\n\t\nend`), the end statement gets wrong indentation.
Solution: Add OPENLINE_FORCE_INDENT flag to make open_line() use
second_line_indent directly (glepnir)
closes: vim/vim#16614
https://github.com/vim/vim/commit/5090a1fecb86c44be83d55e139ed79b7785fa090
|
|
|
|
|
|
|
|
|
|
| |
Problem: When calling an API from Vimscript to set an option, mapping,
etc., :verbose shows that it's set from an API client.
Solution: Don't override current_sctx.sc_sid when calling an API from
Vimscript. Also fix the inverse case where API channel id is
not set when calling an API from RPC. Move channel id into
sctx_T to make saving and restoring easier.
Related #8329
|
|
|
|
|
|
|
|
|
| |
Problem:
luv callback `vim.uv.new_timer():start(0, 0, function() error() end)`
causes SIGSEGV, since `xstrdup` gets NULL from `lua_tostring`.
Similar to: https://github.com/neovim/neovim/commit/a5b1b83a2693ffa7a5a0a22b3693d36ea60051be
Solution:
Check NULL before `xstrdup`.
|
|
|
|
|
|
|
|
|
| |
:SynMenu commands (#32605)
closes: vim/vim#16713
https://github.com/vim/vim/commit/025dc48e88790133ef0da583b2ce5b9c2232ea9e
Co-authored-by: Doug Kearns <dougkearns@gmail.com>
|
|
|
|
|
|
|
|
| |
Problem: illegal memory access when putting a register
Solution: make sure cursor column doesn't become negative
https://github.com/vim/vim/commit/e0029daa3599529d9d438cc51c7ada8580297a39
Co-authored-by: Christian Brabandt <cb@256bit.org>
|
|
|
|
|
|
|
| |
Problem: there is no way to distinguish between user's explicit
completion stop/cancel and other automated reasons.
Solution: update "cancel" reason to be set only on explicit CTRL-e, and
set intentionally vague "discard" otherwise.
|
|
|
|
|
|
|
|
|
| |
Problem: setting title and/or footer without explicitly setting border
shows "title/footer/ requires border to be set" error.
At the same time, explicitly setting `border = "none"` (which is
default) shows expected no-border-no-title-no-footer window without
error.
Solution: allow setting title/footer without explicitly setting border.
|
| |
|
|
|
|
|
| |
#32597
This reverts commit f398e3a61abbf802b49867d2f533be1b0725c0d7.
|
|\ |
|
| | |
|