| Commit message (Collapse) | Author | Age |
| |
|
|
|
|
|
|
|
| |
Problem: Cannot complete the command after ++once or ++nested for
:autocmd.
Solution: Skip over these flags in set_context_in_autocmd() (glepnir).
closes: vim/vim#21429
https://github.com/vim/vim/commit/cf57ec0db8a9bc9926c7ede86a8586f057545723
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Problem: With 'wildmode' set to list:full the matches are listed but the
wildmenu is not shown, although it is "full" that starts
wildmenu mode (zeertzjq).
Solution: List the matches and show the menu, as the two behaviors in
the same phase ask for. The menu is left to the phases that
ask for it, so that "list" on its own still only lists
(Hirohito Higashi).
fixes: vim/vim#21196
closes: vim/vim#21205
https://github.com/vim/vim/commit/fa1ddffcce24f22d61608c0086e55adadd1d2c11
Co-authored-by: Hirohito Higashi <h.east.727@gmail.com>
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Problem: With 'wildmode' set to list:full, matches are listed but the
first match is not completed on the first Tab press (rendcrx).
Solution: Do not suppress selection when list and full are active in
the same completion phase. Add regression tests for file
completion, comma-separated phases and noselect precedence
(Seunghee Kim).
fixes: vim/vim#19532
related: vim/vim#18088
closes: vim/vim#21181
https://github.com/vim/vim/commit/54c988c6c57bff3db35d7df1dcacd484e3d9610c
Co-authored-by: SeungheeKim <ksh368@naver.com>
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
autocommand
Problem: popup_show() from a CmdlineChanged autocommand doesn't update
the screen (Mao-Yining)
Solution: Refresh the screen when popups need redraw
(Yasuhiro Matsumoto).
popup_settext()/popup_show() called from a CmdlineChanged autocommand
did not refresh the screen because cmdline mode normally skips
update_screen(), so async info-popup updates only became visible after
a manual :redraw. Refresh the screen when popups need redrawing right
after the autocommand.
fixes: vim/vim#20175
closes: vim/vim#20179
https://github.com/vim/vim/commit/ef1ecc3b61fd9f462ae3571ed98dd09457659e63
Co-authored-by: Yasuhiro Matsumoto <mattn.jp@gmail.com>
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Problem: Crash when getcompletiontype()/getcompletion() gets a NULL string
(dvaave2025).
Solution: Do not write the NUL terminator in set_cmd_context() when the
cursor column is at or past the end of the string, since the
string may be a read-only literal.
fixes: vim/vim#20963
closes: vim/vim#20964
Supported by AI.
https://github.com/vim/vim/commit/e2dcefa0d8c03a7d2ebda67207e3d1392ae0c402
Co-authored-by: Christian Brabandt <cb@256bit.org>
|
| | |
|
| |
|
|
|
|
|
|
|
| |
Problem:
Want `gQ` for _le multicursor_.
Solution:
- Don't use `gQ` for exmode.
- Introduce `:exmode`.
- Introduce `[count]q:` as an alias to `:exmode`.
|
| |
|
|
|
|
|
|
|
|
|
| |
unnecessary dir (#40565)
Problem: tests: Test_fuzzy_completion_bufname_fullpath() creates an
unnecessary directory with the name of a file.
Solution: Only create the parent directory of the file (zeertzjq).
closes: vim/vim#20695
https://github.com/vim/vim/commit/98efa502798d09d828d5b6f48854145549ab060e
|
| |
|
|
|
|
|
|
|
|
|
| |
Problem: ":filetype detect" is a valid command but not offered by
command-line completion.
Solution: Add "detect" to the completion candidates (glepnir)
closes: vim/vim#20625
https://github.com/vim/vim/commit/984f29860ed4e7259de932ca7a8027e650efae7a
Co-authored-by: glepnir <glephunter@gmail.com>
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Problem:
cmdwin (the `:q` cmdline buffer) has various limitations which require
special-casing all over the codebase.
Besides complicating the code, it also breaks async plugins if they try
to create buffers/windows after some work is done, if the user happens
to open cmdwin at the wrong the moment:
Lua callback: …/guh.nvim/lua/guh/util.lua:531:
E11: Invalid in command-line window; <CR> executes, CTRL-C quits
stack traceback:
[C]: in function 'nvim_buf_delete'
…/guh.nvim/lua/guh/util.lua:531: in function <…/guh.nvim/lua/guh/util.lua:526>
Solution:
Just say no to "inception". Reimplement cmdwin as a normal buffer+window.
All of the cmdwin contortions (in both core, and innocent plugins) exist
literally only to support "inception": recursive
cmdwin-in-cmdline-things, like `<c-r>=`, `/`, search-during-substitute,
`:input()`, etc. So we just won't support that (though I have
a potential plan for that later, which I call "modal parking lot").
The benefit is that plugins, and core, no longer have to care about
cmdwin.
BONUS:
- mouse-drag on vertical separators works (it only worked for
horizontal/statusline before)
- inccommand-in-cmdwin now works correctly, for free (thus don't need
#40077).
POTENTIAL FOLLOWUPS
- Drop `CHECK_CMDWIN` ("E11: Invalid in command-line window"), allow chaos.
- Unify `BUFLOCK_OK` / `LOCK_OK` ?
DESIGN:
- Eliminate lots of C globals, `EX_CMDWIN`, etc.
- `text_locked()` no longer reports true for cmdwin.
- cmdwin = a normal window with 'winfixbuf', 'bufhidden=wipe',
'buftype=nofile'. Invariants come from those options rather than
special cases throughout the codebase.
- `nv_record` for q:/q//q? calls Lua
`nlua_call_vimfn("vim._core.cmdwin", …)`. No `K_CMDWIN`
/ cmdline-reader detour.
- `cedit_key` (`c_CTRL-F`) schedules a deferred event that calls
`vim._core.cmdwin.open(type, content, pos)` and returns `Ctrl_C` so
the in-flight cmdline cancels. Reader state is not serialized; instead
the captured `(type, line, col)` is replayed via
`nvim_feedkeys(type..line.."<CR>", "nt", …)` after user confirms.
- On confirm/cancel: `<CR>` / `<C-C>` calls into Lua which closes the
window and re-feeds the cmdline.
BREAKING CHANGES:
- Expression-register cmdline (`<C-R>=` from insert-mode) no longer
supports cmdwin. Same applies to `input()` / `inputlist()` (already
covered by `text_locked`).
- Usage of cmdwin in macros/mappings will probably break (assuming they
ever worked).
|
| |
|
|
|
|
|
|
|
|
|
|
| |
Problem: ":filetype plugin<Tab>" gives "pluginindent" because a
sub option before the cursor is treated as already given.
Solution: only skip plugin and indent when followed by white space.
(glepnir)
closes: vim/vim#20594
https://github.com/vim/vim/commit/fe65f23aca22c40d5e919aa0e4f2909bf57d8d94
Co-authored-by: glepnir <glephunter@gmail.com>
|
| |
|
|
|
|
|
|
|
| |
Problem: tests: test_cmdline.vim leaves swapfiles behind
Solution: Close open buffers using :bw! instead of :close!
https://github.com/vim/vim/commit/bf1b41e387eb47421a256b9a4eb9c01ae29099ee
Co-authored-by: Christian Brabandt <cb@256bit.org>
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
mouse (#40142)
Problem: In command-line completion with a popup menu ('wildoptions'
contains "pum"), the info popup shown next to the menu could
not be scrolled, unlike the Insert mode completion info popup
which scrolls with the mouse wheel.
Solution: When the mouse pointer is on top of the info popup, scroll it
with the mouse wheel in command-line mode as well, without
closing the completion popup menu.
closes: vim/vim#20146
closes: vim/vim#20418
https://github.com/vim/vim/commit/96dbab257a881ee4a552e1acf62e7d4168dc444a
Co-authored-by: Hirohito Higashi <h.east.727@gmail.com>
Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
'ignorecase' (#39944)
Problem: completion: cannot complete user cmd :K with 'ignorecase'
(rendcrx)
Solution: Skip the short-circuit when 'ignorecase' is set
(Yasuhiro Matsumoto)
The set_cmd_index() short-circuit for the :k command treats ":k<X>" as
":k {X}" (mark argument), which makes ":kz<Tab>" never reach the
command-name expansion path. With 'ignorecase' the same prefix on other
letters (":gz<Tab>") completes a user command like :Gz, so the result is
inconsistent. Skip the short-circuit when 'ignorecase' is set; default
behaviour is preserved so the existing :k tests still pass.
fixes: vim/vim#20241
closes: vim/vim#20275
https://github.com/vim/vim/commit/b54e57ee54f0a4e6eac74b071071a9d85326de3a
Co-authored-by: Yasuhiro Matsumoto <mattn.jp@gmail.com>
|
| |
|
|
|
|
|
|
|
| |
Problem: No test that "abbr" in customlist completion is shown in pum.
Solution: Add some "abbr" fields to the existing test (zeertzjq).
closes: vim/vim#20165
https://github.com/vim/vim/commit/b207b5a2a38dd8f45417e69c2e659c4c05ad3c1e
|
| |
|
|
|
|
|
|
|
|
|
|
| |
Problem: 'findfunc' can't return extra info for cmdline completion
(Maxim Kim).
Solution: Handle 'findfunc' return value in cmdline completion like that
of "customlist" functions (zeertzjq).
fixes: vim/vim#20155
closes: vim/vim#20158
https://github.com/vim/vim/commit/58124789aaf98fd96cd94a738633fd652a5e079a
|
| |
|
|
|
|
|
|
|
|
|
|
| |
customlist (#39614)
Problem: Completion with i_CTRL-X_CTRL-V doesn't use dict from cmdline
"customlist" completion.
Solution: Include abbr/kind/menu/info in the completion items
(zeertzjq).
closes: vim/vim#20139
https://github.com/vim/vim/commit/2bfddbea47e1afa79ecd094040418abdba88bc83
|
| |
|
|
|
|
|
|
|
|
|
|
| |
Problem: Info popup isn't removed when selecting an item that doesn't
have "info" in cmdline completion, which is inconsistent with
Insert mode behavior.
Solution: Set pum_call_update_screen in cmdline mode (zeertzjq).
closes: vim/vim#20128
https://github.com/vim/vim/commit/3bfffcc29054faff2dbec2d765317ee09e9ef827
Nvim already behaves correctly. Add a screen test as there are none.
|
| |
|
|
|
|
|
|
|
|
|
|
| |
Problem: customlist completion cannot supply pum metadata
Solution: Allow each item returned by a customlist function to be
either a string or a Dict with keys "word", "abbr", "kind",
"menu" and "info" (Yasuhiro Matsumoto).
closes: vim/vim#20100
https://github.com/vim/vim/commit/5c700152ae23c91b6edef3fa3e7ba06d40be0f9e
Co-authored-by: Yasuhiro Matsumoto <mattn.jp@gmail.com>
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
(#39517)
Problem: With $d='[dir]', `:e $d/file.txt` opens the wrong file,
`:e $d/<Tab>` fails to complete, and `glob('$d/*')` returns
nothing. Wildcard characters inside expanded environment
variables get picked up by globbing again.
Solution: Turn the 4th parameter of expand_env_esc() from a bool into a
string of characters to escape in each expanded value. Callers
that pass the result to wildcard expansion should include
PATH_ESC_WILDCARDS in addition to " \t" (glepnir).
closes: vim/vim#20053
https://github.com/vim/vim/commit/20e98ff1cc3ffc13d42579d2bf9b9567f98595a2
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
single-file Ex commands (#39520)
Problem: SPACE_IN_FILENAME is defined on most platforms but not on Unix.
As a result, set_context_for_wildcard_arg() on Unix always resets the
completion pattern at white space for Ex commands that take a
single file argument.
Solution: Drop the SPACE_IN_FILENAME ifdef (Maxim Kim)
fixes: vim/vim#18411
closes: vim/vim#20090
https://github.com/vim/vim/commit/c2bda0add96a18328299e9fe6d75925049a5146a
Co-authored-by: Maxim Kim <habamax@gmail.com>
|
| |
|
|
|
|
|
|
|
|
|
|
|
| |
(#39516)
Problem: completion: no support for "noinsert" with 'wildmode' and
commandline completion
Solution: Add "noinsert" value to the 'wildmode' option, mirroring
'completeopt' "noinsert" behaviour (glepnir).
fixes: vim/vim#16551
closes: vim/vim#20080
https://github.com/vim/vim/commit/af494af5ff188d976073cbc049249614edffa4bf
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
(#39072)
Problem: Wrong cursor position when entering command line window
Solution: Add check_cursor() command to verify the cursor position
(Hirohito Higashi).
When opening the command-line window with CTRL-F after typing a command
that fills the screen width, the cursor was placed past the end of the
line. Add check_cursor() after setting State to MODE_NORMAL so the
cursor is adjusted to the last character.
Also fix the cmdwin prefix character (e.g. ':') being drawn on wrapped
continuation rows. Draw an empty space instead so that the text
alignment is preserved.
closes: vim/vim#19964
https://github.com/vim/vim/commit/c4fe1e958a2051d443abe072c8a5366a887da9b3
Cherry-pick Test_wildmenu_pum() changes from patch 9.1.1995.
Co-authored-by: Hirohito Higashi <h.east.727@gmail.com>
Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
|
| |
|
|
|
|
|
|
|
|
|
|
|
| |
statusline like option (#39063)
Problem: potential buffer underrun when settings statusline like option
(q1uf3ng)
Solution: Validate that p > out before accessing p[-1]
closes: vim/vim#19961
https://github.com/vim/vim/commit/91b402f57575ed33649285043a3c631701165f4a
Co-authored-by: Christian Brabandt <cb@256bit.org>
|
| |
|
|
|
|
|
|
|
|
|
|
|
| |
Problem: Vim may freeze if setcmdline() is called while the wildmenu or
cmdline popup menu is active (rendcrx)
Solution: Cleanup completion state if cmdbuff_replaced flag has been set
(Yasuhiro Matsumoto)
fixes: vim/vim#19742
closes: vim/vim#19744
https://github.com/vim/vim/commit/332dd22ed48244d67524933453049c6c866bcabf
Co-authored-by: Yasuhiro Matsumoto <mattn.jp@gmail.com>
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Problem: CI Tests favor GTK2 over GTK3
Solution: Install GTK3 dependencies and debug packages for CI workflows,
update ASAN suppression list, update required dependency
checks for the tests (Drew Vogel)
closes: vim/vim#17253
https://github.com/vim/vim/commit/ea67ba718d8af10cb7aa3b91379203f5dd7e50d7
Cherry-pick test_match.vim changes from patch 9.0.0626.
Co-authored-by: Drew Vogel <dvogel@github>
|
| |
|
|
|
|
|
|
|
|
|
|
|
| |
Problem: Esc on commandline executes command instead of abandoning it.
Solution: Save and restore KeyTyped when removing the popup menu.
(closes vim/vim#10154)
https://github.com/vim/vim/commit/11a57dfd16a47f248fe949344bd5db3f12b9bd32
No code change is needed in Nvim as Nvim doesn't call update_screen() to
redraw pum.
Co-authored-by: Bram Moolenaar <Bram@vim.org>
|
| |
|
|
|
|
|
|
|
| |
Problem: :normal may change cmdline history if the keys don't
explicitly leave Cmdline mode (after 9.1.1872).
Solution: Check ex_normal_busy (zeertzjq)
closes: vim/vim#19237
https://github.com/vim/vim/commit/85241020e808a74221a4befa367ceeda76af7ee0
|
| |
|
|
|
|
|
|
|
|
|
| |
(#37466)
Problem: Crash with 'wildmenu' when typing Ctrl-Y after Ctrl-A
(after 9.1.1714) (fizz-is-on-the-way).
Solution: Check if there are matches before applying one (zeertzjq).
closes: vim/vim#19210
https://github.com/vim/vim/commit/311b98d94256038fd2a5a823edcb6ab50d2fc8e8
|
| |
|
|
|
|
|
|
|
| |
Problem: Vim9: completion for :disassemble adds parenthesis.
Solution: Don't add parenthesis. (Naohiro Ono, closes vim/vim#8802)
https://github.com/vim/vim/commit/9aecf79c45da5593e4d8c0de1b2d212edc4765ce
Co-authored-by: naohiro ono <obcat@icloud.com>
|
| |
|
|
|
|
|
|
|
| |
Problem: Vim9: :disass completion does not understand "s:".
Solution: Expand "s:" to a pattern. (closes vim/vim#8780)
https://github.com/vim/vim/commit/47016f57724d3970c54f4ca1f392dff39d3fecae
Co-authored-by: Bram Moolenaar <Bram@vim.org>
|
| |
|
|
|
|
|
|
|
|
|
| |
Problem: Vim9: completion for :disassemble is incomplete.
Solution: Recognize the "debug" and "profile" arguments.
https://github.com/vim/vim/commit/4ee9d8e04daa97a3d0a19d7d2eed76b7721301e6
Vim9 ":disassemble" is N/A.
Co-authored-by: Bram Moolenaar <Bram@vim.org>
|
| |
|
|
|
|
|
|
|
|
|
|
|
| |
Problem: Completion for :disas sorts local functions first.
Solution: Sort local functions last, like with :delfunc. (Naohiro Ono,
closes vim/vim#8860)
https://github.com/vim/vim/commit/dfe04dbff5863f6c089da8831d7ac2a3421a44b7
Vim9 ":disassemble" is N/A
but "commented" test code is a hint for future patches.
Co-authored-by: naohiro ono <obcat@icloud.com>
|
| |
|
|
|
|
|
|
|
|
|
|
|
| |
Problem:
- Despite [nvim-lspconfig](https://github.com/neovim/nvim-lspconfig)
claims to be a "data-only" plugin, in fact it still provides some
user-facing commands because they haven't been upstreamed to Nvim.
Solution:
- Upstream `:LspRestart`, `:LspStart` and `:LspStop` commands as `:lsp
restart`, `:lsp start` and `:lsp stop` respectively.
Co-authored-by: glepnir <glephunter@gmail.com>
|
| |
|
|
|
|
|
|
|
|
| |
Problem: Accessing beyond allocated memory when using the cmdline window in
Ex mode.
Solution: Use "*" instead of "'<,'>" for Visual mode.
https://github.com/vim/vim/commit/c6fdb15d423df22e1776844811d082322475e48a
Co-authored-by: Bram Moolenaar <Bram@vim.org>
|
| |
|
|
|
|
|
|
|
|
| |
redrawing (#36642)
Problem: tests: not enough testing for wildtrigger() pum redrawing.
Solution: Also test redrawing when leaving cmdline mode (zeertzjq).
closes: vim/vim#18773
https://github.com/vim/vim/commit/eb33c2eb2815edffab3f4abd4cb8617e37ccca40
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
| |
Problem: :breaklist accepts unprocessed arguments.
Solution: Remove EX_EXTRA flag from the Ex command definition.
(Doug Kearns)
The command should emit an "E488: Trailing characters" error rather than
silently accept arguments.
closes: vim/vim#18746
https://github.com/vim/vim/commit/de7049ede1a31c73bfac70b78a2613d690eb1594
Co-authored-by: Doug Kearns <dougkearns@gmail.com>
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
(#36334)
Problem: Cmdline history not updated when mapping both <Up> and <CR>.
Solution: Consider the command typed when in Cmdline mode and there is
no pending input (zeertzjq).
Although the existing behavior technically does match documentation, the
"completely come from mappings" part is a bit ambiguous, because one may
argue that the command doesn't completely come from mappings as long as
the user has typed a key in Cmdline mode. I'm not entirely sure if this
change will cause problems, but it seems unlikely.
fixes: vim/vim#2771
related: neovim/neovim#36256
closes: vim/vim#18607
https://github.com/vim/vim/commit/97b6e8b4243cc96dbb8716d518976a5ce0515748
|
| |
|
|
|
|
|
|
|
|
|
|
| |
:echowindow (#36157)
Problem: No cmdline completion for :echoconsole, :echowindow and second
expression after :echoerr.
Solution: Set EXPAND_EXPRESSION for :echoconsole and :echowindow, and
check for multiple expressions after :echoerr (zeertzjq).
closes: vim/vim#18552
https://github.com/vim/vim/commit/7aaca97fc5154bb2f2483237b49e25786a061379
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Problem: complete: some redraw issues with 'autocomplete'
Solution: Fix the issues (Girish Palya)
This commit contains the following changes:
* Fix that wildtrigger() might leave opened popupmenu around vim/vim#18298
* Remove blinking message on the command line when a menu item from a loaded
buffer is selected during 'autocomplete'
* Add a test for PR vim/vim#18265 to demonstrate why the PR is required for correct
'autocomplete' behavior
fixes: vim/vim#18298
closes: vim/vim#18328
https://github.com/vim/vim/commit/ee9a2f0512e8b732e3c6a000974aa7e3f6028989
Co-authored-by: Girish Palya <girishji@gmail.com>
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Problem: When the popup menu (PUM) occupies more than half the screen
height, it flickers whenever a character is typed or erased.
This happens because the PUM is cleared and the screen is
redrawn before a new PUM is rendered. The extra redraw between
menu updates causes visible flicker.
Solution: A complete, non-hacky fix would require removing the
CmdlineChanged event from the loop and letting autocompletion
manage the process end-to-end. This is because screen redraws
after any cmdline change are necessary for other features to
work.
This change modifies wildtrigger() so that the next typed
character defers the screen update instead of redrawing
immediately. This removes the intermediate redraw, eliminating
flicker and making cmdline autocompletion feel smooth
(Girish Palya).
Trade-offs:
This behavior change in wildtrigger() is tailored specifically for
:h cmdline-autocompletion. wildtrigger() now has no general-purpose use
outside this scenario.
closes: vim/vim#17932
https://github.com/vim/vim/commit/da9c9668931e5c8ee4dc0e430898ad2d80f56862
Use pum_check_clear() instead of update_screen().
Cherry-pick Test_wildtrigger_update_screen() change from patch 9.1.1682.
Co-authored-by: Girish Palya <girishji@gmail.com>
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
'autocomplete' (#35692)
Problem: complete: preinsert does not work well with preinsert
Solution: Make "preinsert" completeopt value work with autocompletion
(Girish Palya)
This change extends Insert mode autocompletion so that 'preinsert' also
works when 'autocomplete' is enabled.
Try: `:set ac cot=preinsert`
See `:help 'cot'` for more details.
closes: vim/vim#18213
https://github.com/vim/vim/commit/fa6fd41a943e6442c1a2ce6b0a237298b00ecca0
Co-authored-by: Girish Palya <girishji@gmail.com>
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
| |
Problem: tests: Test_skip_wildtrigger_hist_navigation() may fail
(zeertzjq).
Solution: Correct test to validate intended behavior (Girish Palya).
See https://github.com/vim/vim/pul |