Problem:
Despite the name, `builtin.txt` only includes Vimscript functions, which
is confusing, especially to people who only use Lua to configure Nvim
Solution: From justinmk's suggestion
- Rename `builtin.txt` to `vimfn.txt`
- Rename `eval.txt` to `vimeval.txt`
- The tags `*builtin.txt*` and `*eval.txt*` should be kept for Vim-patches
Closes#33743
Problem:
Currently undefined behavior can occur when `string_fragment()` is
called with `OSC_COMMAND`. This is because when the state changes to
`OSC_COMMAND`, `string_initial` is set to true. Then in some cases,
directly after this `string_initial` will be set back to false before
the on_osc callback is called, this leads to `term_settermprop()` never
initializing the title.
Solution:
In all of the no-op cases in `string_fragment()` currently, we continue
to the end of the function where `vt->parser.string_initial` is set to
false. This change returns in the no-op cases instead since in these
cases the string has not yet been terminated and sent to the callback.
Note:
This change also adds a test with a byte sequence from the file
in #34028 that caused nvim to crash. This byte sequences is the shortest
sequence I could trim down from that file that still would trigger the
crash. There are also two other tests I added which validate that
setting the title with OSC-0 and OSC-2 still works.
Fixes: #34028
Problem: `TSLangInfo` annotation does not reflect the structure returned
by `vim.treesitter.language.inspect()`.
Solution: Move version information under new (optional since ABI 15 only)
`TSLangMetadata` field.
Problem:
vim.uv.spawn will emit ENOENT for either when the cmd or cwd do not
exist and does not tell you which.
Solution:
If an error occurs, check if cwd was supplied and included in the error
message if it does not exist.
Problem: missing info about register completion in complete_info()
(after v9.1.1408)
Solution: update documentation and mention that register is used as
source, add a test (glepnir)
closes: vim/vim#1738949864aecd0
Co-authored-by: glepnir <glephunter@gmail.com>
Problem: not easily possible to complete from register content
Solution: add register-completion submode using i_CTRL-X_CTRL-R
(glepnir)
closes: vim/vim#173540546068aae
Problem: Unable to emit a message with arbitrary kind.
Solution: Add a "kind" opts field to nvim_echo().
Use it to set the "list_cmd" kind for vim.show_pos().
Problem: Calculated cmdline cursor position can be smaller than 0.
Prompt part of the cmdline is translated, while it should
support "\t" characters.
Solution: Remove prompt part from the stored "cmdbuff" and get rid of
dubious +/-1 from cmdline cursor calculation.
Problem: An already open "more" window is the most convenient place
to route messages to with `cfg.msg.pos == 'cmd'`. Instead we
route to the cmdline (unless that message also exceeds
'cmdheight').
Solution: Route to "more" window while it is open and scroll to bottom
to show the newest message. This is more convenient and more
efficient due to not writing to the target buffer first (which
is done to calculate the height of the message).
(Ensure message highlights are deleted when text is replaced.)
Problem: Search highlighting is applied strangely to the filler text of
transparent folds, and EOL list characters are not shown.
Solution: Don't apply search highlighting to the last column of the window row
if the last text char on the line is highlighted. Display the EOL list char if
needed. Don't highlight the entire filler text when matching EOL, just highlight
the EOL list char or the first filler char.
Problem: spurious CursorHold triggered in GUI on startup
Solution: init global did_cursorhold flag to true
(Gary Johnson)
When Vim is started in GUI mode, the CursorHold autocommand event is
triggered 'updatetime' milliseconds later, even when the user has not
pressed a key. This is different from the behavior of Vim in terminal
mode, which does not trigger a CursorHold autocommand event at startup,
and contradicts the description of the CursorHold event in ":help
CursorHold", which states that the event is "[n]ot triggered until the
user has pressed a key".
The fix is to change the initial value of did_cursorhold from FALSE to
TRUE. While it is true that the CursorDone event has not been done yet
at startup, it should appear to have been done until the user presses
a key.
fixesvim/vim#17350closes: vim/vim#17382318ff9c362
Co-authored-by: Gary Johnson <garyjohn@spocom.com>
This prevents Nvim TUI running in tests from thinking it's inside tmux.
Another solution is make :terminal unset $TMUX instead, but I'm not sure
if that'll break some other use cases.
Problem: Bulking message lines to write in a single API call is
complicated and still not correct w.r.t. overwriting
highlights.
Solution: Write each chunk pattern separately with it's highlight
such that it will be spliced correctly for message chunks
that contain a carriage return. Go with correctness over
performance until this proves to be too inefficient.
Also add an identifying name to the various extui buffers.
Problem: Can't use getpos('v') in OptionSet when using setbufvar().
Solution: Don't reset Visual selection when switching to the same
buffer (zeertzjq).
closes: vim/vim#173735717ee33db
Problem: Using tracked message column as column in cleared buffer.
Solution: Ensure column does not exceed current line length.
Further work to ensure carriage return and cmdline block mode
work properly.
Problem: "99 searchcount ought to be enough for anyone."
Solution: Increase `SEARCH_STAT_DEF_MAX_COUNT` to 999, which I'm sure
will suffice for the next twenty years.
Co-authored-by: Sean Dewar <6256228+seandewar@users.noreply.github.com>
Problem: Consecutive "msg_show" events stemming from an `:echon`
command are supposed to be appended without a newline, this
information is not encoded in the "msg_show" event.
Solution: Add an "append" parameter to the "msg_show" event that is set
to true to indicate the message should not start on a new line.
Considered alternative: Emit a newline for the common case instead at the
start of a new message. That way UIs can more closely follow the logic
as it is implemented for the message grid currently. This would be a
breaking change. The "append" parameter seems OK.
Problem: When scrolling (the text) down with 'smoothscroll', filler
lines are revealed before the text skipped with `w_skipcol`.
Solution: Check `w_skipcol` before filler lines.
Problem: tests: no test for mapping with special keys in session file.
Solution: Add a special keys to an existing test. Also test with UTF-8
characters containing 0x80 or 0x9b bytes (zeertzjq).
closes: vim/vim#173609ff1e598e8
Problem: wrong link to Chapter 2 in vim-01-beginner.tutor
Solution: Fix the link to Chapter 2, add test for links in tutor files
(Phạm Bình An)
In order to write the test, I exposed the function `s:GlobTutorials` as
`tutor#GlobTutorials` and make it also accept a `locale` argument.
closes: vim/vim#17356e8302da74a
Co-authored-by: Phạm Bình An <111893501+brianhuster@users.noreply.github.com>
Problem: multi-byte mappings not properly stored in session file
Solution: unescape the mapping before writing out the mapping, prefer
single-byte mapping name if possible (Miguel Barro)
closes: vim/vim#173555b07aff2f6
Co-authored-by: GuyBrush <miguel.barro@live.com>