| Commit message (Collapse) | Author | Age |
... | |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Problem: Current instance of last search pattern not easily spotted.
Solution: Add CurSearch highlighting. (closes vim/vim#10133)
https://github.com/vim/vim/commit/a43993897aa372159f682df37562f159994dc85c
Some code is superseded by later patches that are already ported.
Co-authored-by: LemonBoy <thatlemon@gmail.com>
|
| |
| |
| |
| |
| |
| | |
Problem: Hit assert when clicking inside a padded 'statuscolumn' that
is padded beyond the length of the allocated click_defs.
Solution: Still consider this a "in_statuscol" click, but return early
when about to execute the click func.
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
(#29397)
Problem: getcmdcompltype() interferes with cmdline completion.
Solution: Don't set expand context when it's already set.
(zeertzjq)
closes: vim/vim#15036
https://github.com/vim/vim/commit/a821b609f9bb9daef032fe1cb8fb95995822e367
|
| |
| |
| |
| | |
Also change the initial value of `status` to `FAIL`, as that'll avoid
unnecessary assignments.
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Followup to #28515:
Rename the static os_homedir() to os_uv_homedir() to emphasize that it
is a wrapper around a libuv function.
Add the function os_get_homedir() to os/env.c to return the cached
homedir value as a const. Must be called after homedir is initialized or
it fails.
The difference between this function and the static os_uv_homedir() is
that the latter gets the homedir from libuv and is used to initialize
homedir in init_homedir(), while os_get_homedir() just returns homedir
as a const if it's initialized and is public.
Use the os_get_homedir() accessor for ~/ expansion on Windows to make
the code more concise.
Add a Windows section to main_spec.lua with tests for expanding ~/ and
~\ prefixes for files passed in on the command-line.
Signed-off-by: Rafael Kitover <rkitover@gmail.com>
|
| |
| |
| |
| |
| | |
Do the expansion right after setting the expand context, so that the
length of the completion prefix can be set, but don't do that directly
in set_one_cmd_context(), as that's also called by getcmdcompltype().
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Problem: matched text is highlighted case-sensitively
Solution: use MB_STRNICMP, update highlighting when the base changes
(glepnir)
fixes: vim/vim#15021
closes: vim/vim#15023
https://github.com/vim/vim/commit/f189138b39a11ed5cf3adea6610469b478841aba
Co-authored-by: glepnir <glephunter@gmail.com>
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Problem: Matched text isn't highlighted in cmdline pum.
Solution: Use cmdline completion pattern in cmdline mode.
(zeertzjq)
closes: vim/vim#15029
https://github.com/vim/vim/commit/d8c9340fc67ca19f82ec3e77ec38296424e758cf
Cherry-pick syntax.txt change from runtime update.
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
(#29371)
Problem: Wrong matched text highlighted in pum with 'rightleft'.
Solution: Match using the original text instead of the reversed text.
(zeertzjq)
closes: vim/vim#15020
https://github.com/vim/vim/commit/63901e89638d683ecbc8e3323170dd485657fd1d
|
| |\
| | |
| | | |
feat(column)!: rework 'statuscolumn' %r/l items
|
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Problem: A custom 'statuscolumn' needs to check a bunch of options and
placed signs to replicate the default number column.
Solution: Rework %l item to include the necessary logic to mimic the
default number column. Remove now redundant %r item.
|
| | |
| | |
| | |
| | |
| | | |
Immediately write to buf_tmp instead of to another temporary buffer that
is later copied to buf_tmp. Misc cleanup.
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Problem: default completion may break with fuzzy
Solution: check that completion_match_array is not null
(glepnir)
closes: vim/vim#15010
https://github.com/vim/vim/commit/aced8c2f4fd1cf3f8ac7cdb0dd54d19ef4390ef8
Co-authored-by: glepnir <glephunter@gmail.com>
|
| | | |
|
| |/
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Problem: Cmdline pum doesn't work properly with 'rightleft'.
Solution: Don't use curwin->w_p_rl in cmdline mode in pum_redraw(). Use
a static variable since pum_may_redraw() may be called in any
mode. Also correct position of other popups with 'rightleft'.
(zeertzjq)
closes: vim/vim#15005
https://github.com/vim/vim/commit/883018feff43413813770dd1e13d4f950aa38524
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Problem: minor style problems with patch 9.1.0487
Solution: use shown_compl instead of after_first_compl variable
(glepnir)
closes: vim/vim#15008
fix(completion): use exist shown_compl instead after_first_compl
https://github.com/vim/vim/commit/105f741fac1b3242909c3c69384f00e4dcd9356e
Co-authored-by: glepnir <glephunter@gmail.com>
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Problem: Wrong padding for pum "kind" with 'rightleft'.
Solution: Fix off-by-one error (zeertzjq).
The screen_fill() above is end-exclusive, and
- With 'rightleft' it fills `pum_col - pum_base_width - n + 1` to `col`,
so the next `col` should be `pum_col - pum_base_width - n`.
- With 'norightleft' it fills `col` to `pum_col - pum_base_width + n - 1`,
so the next `col` should be `pum_col - pum_base_width + n`.
closes: vim/vim#15004
https://github.com/vim/vim/commit/a2324373eb1c3f1777bc40cb6dcd5e895a15fe10
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Problem: completed item not update on fuzzy completion
Solution: reset compl_shown_match when at original match position
(glepnir)
closes: vim/vim#14955
https://github.com/vim/vim/commit/f94c9c482a6dd488f0136ac99499eb6e2ab3ccca
Co-authored-by: glepnir <glephunter@gmail.com>
|
| |
| |
| |
| |
| |
| | |
Co-authored-by: Ilia Choly <ilia.choly@gmail.com>
Co-authored-by: Jose Pedro Oliveira <jose.p.oliveira.oss@gmail.com>
Co-authored-by: Maria José Solano <majosolano99@gmail.com>
Co-authored-by: zeertzjq <zeertzjq@outlook.com>
|
| |
| |
| |
| |
| |
| | |
https://github.com/vim/vim/commit/c509c009bbc07eff678a9239a5813398e180f019
Co-authored-by: Christian Brabandt <cb@256bit.org>
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
meaning
related: vim/vim#14991
https://github.com/vim/vim/commit/d6d4e1333659c0d2acee3133819498d014df47de
Co-authored-by: Christian Brabandt <cb@256bit.org>
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Problem: Matched text shouldn't be highlighted in "kind" and "menu".
Solution: Pass hlf_T instead of the attribute. Fix indent.
(zeertzjq)
closes: vim/vim#14996
https://github.com/vim/vim/commit/afbe5359e981e5d19ad23c394aefe60395c3648e
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Problem: fuzzy string matching executed when not needed
Solution: when no leader is available, can skip fuzzy logic, so return
early (glepnir)
closes: vim/vim#14986
https://github.com/vim/vim/commit/1c296026627d7ac8195e803b4c2393c21ae659b4
Co-authored-by: glepnir <glephunter@gmail.com>
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Problem: fuzzy_match_str_with_pos() does unnecessary list operations.
Solution: Use fuzzy_match() directly (zeertzjq).
closes: vim/vim#14987
https://github.com/vim/vim/commit/2f95ca9fcef8495d60e298ac2cd6d702b90bfb18
N/A patch:
vim-patch:9.1.0478: potential deref of NULL pointer in fuzzy_match_str_with_pos
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Problem: Cannot see matched text in popup menu
Solution: Introduce 2 new highlighting groups: PmenuMatch and
PmenuMatchSel (glepnir)
closes: vim/vim#14694
https://github.com/vim/vim/commit/40c1c3317d92f8c2adadf744fab72e4458e2a9fa
Co-authored-by: glepnir <glephunter@gmail.com>
|
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Problem: Sorting of completeopt+=fuzzy is not stable.
Solution: Compare original indexes when scores are the same.
(zeertzjq)
closes: vim/vim#14988
https://github.com/vim/vim/commit/8e56747fd26b3b040b6fcbfb6be41b7d5922c6b5
|
| |\
| | |
| | | |
refactor(shada): use msgpack_sbuffer less
|
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Work towards getting rid of libmsgpack depedency eventually.
msgpack_sbuffer is just a string buffer, we can use our own
String type.
|
| | |
| | |
| | |
| | |
| | | |
revert: "refactor: use S_LEN(s) instead of s, n (#29219)"
This reverts commit c37695a5d5f2e8914fff86f3581bed70b4c85d3c.
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
virtcol() (vim/vim#14981)
These are different from line() and getpos().
https://github.com/vim/vim/commit/d353d2782032b91498601afefee4256592f48074
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Move the main description to getpos() and link to that from the other
functions.
closes: vim/vim#14970
https://github.com/vim/vim/commit/02f3ebacfbfa1f892347d7532278f24620e68300
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
The ui_rgb_attached function determines if any UI is attached which
supports RGB (truecolor). We determine if the TUI supports RGB via the
'termguicolors' option which is checked at the beginning of this
function. If the TUI does not support RGB ('termguicolors' is unset), we
check to see if any _other_ UI is attached which supports RGB.
Normally, the TUI's "rgb" flag and the 'termguicolors' option are the
same. However, they may differ during startup when the "rgb" flag is set
by tui/tui.c to indicate to the core that the terminal emulator supports
truecolor. The 'termguicolors' option is not actually set until
_defaults.lua runs.
|
| | | |
|
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
These highlight groups are used for the statusline in :terminal windows.
By default they link to StatusLine and StatusLineNC (respectively), so
there is no visual difference unless a colorscheme defines these groups
separately.
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
line() (#29296)
Problem: the previous documentation falsely states that "v" always
refers to the start of a visual area. In fact, the reference of "v" and
"." complement each other. If the cursor is at the start of
a (characterwise) visual area, then "v" refers to the end of the area.
Solution: be more verbose and explicit about the connection between "."
and "v" and also refer to |v_o| which many vim users will be familiar
with for visual areas.
https://github.com/vim/vim/commit/210b39c2d686d875e2464ca1f42131453dc6bd41
Co-authored-by: Peter Aronoff <peter@aronoff.org>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
(#29117)
When libvterm receives the OSC 52 escape sequence it ignores it because
Nvim does not set any selection callbacks. Install selection callbacks
that forward to the clipboard provider, so that setting the clipboard
with OSC 52 in the embedded terminal writes to the system clipboard
using the configured clipboard provider.
|
| |\ \
| | | |
| | | | |
refactor(memory): use builtin strcat() instead of STRCAT()
|
| | |/
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
The latter was mostly relevant with the past char_u madness.
NOTE: STRCAT also functioned as a counterfeit "NOLINT" for clint
apparently. But NOLINT-ing every usecase is just the same as disabling
the check entirely.
|
| | | |
|
| | |
| | |
| | |
| | |
| | |
| | | |
Problem: Some vim.fn have no type annotations.
Solution: Add type annotations.
|
| |/ |
|
| |
| |
| |
| |
| |
| |
| |
| | |
Problem: Legacy :sign API still allows placing signs beyond the end of
the buffer. This is unaccounted for by the signcolumn tracking
logic and is disallowed in general for the extmark API which
implements it now.
Solution: Clamp legacy sign line number to the length of the buffer.
|
| |
| |
| |
| |
| |
| |
| |
| | |
`nvim_get_option_value` throws a warning if both `scope` and `buf`
options are used at the same time. This is because using `buf` always
implies `scope` is local, and is therefore not needed. There's however
no need to error if `scope` is already set "local" as it's the correct
value.
|
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Problem: Inconsistencies between functions for option flags.
Solution: Consistently use "unsigned int" as return type and rename
get_bkc_value() to get_bkc_flags() (zeertzjq).
closes: vim/vim#14925
https://github.com/vim/vim/commit/aa925eeb97bd294d4a5253a3194949a37cbc8365
|
| |
| |
| |
| | |
DynamicBuffer at home: KVÄCK
|
| |\
| | |
| | | |
refactor(io): make rstream use a linear buffer
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
If you like it you shouldn't put a ring on it.
This is what _every_ consumer of RStream used anyway, either by calling
rbuffer_reset, or rbuffer_consumed_compact (same as rbuffer_reset
without needing a scratch buffer), or by consuming everything in
each stream_read_cb call directly.
|
| |/
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
It's a function to perform operations in their own sealed context,
similar to pythons `with`. This helps ease operations where you need to
perform an operation in a specific context, and then restore the
context.
Marked as private for now as it's not ready for public use. The current
plan is to start using this internally so we can discover and fix any
problems. Once this is ready to be exposed it will be renamed to
`vim.with`.
Usage:
```lua
local ret = vim._with({context = val}, function()
return "hello"
end)
```
, where `context` is any combination of:
- `buf`
- `emsg_silent`
- `hide`
- `horizontal`
- `keepalt`
- `keepjumps`
- `keepmarks`
- `keeppatterns`
- `lockmarks`
- `noautocmd`
- `options`
- `sandbox`
- `silent`
- `unsilent`
- `win`
(except for `win` and `buf` which can't be used at the same time). This
list will most likely be expanded in the future.
Work on https://github.com/neovim/neovim/issues/19832.
Co-authored-by: Lewis Russell <lewis6991@gmail.com>
|
| |
| |
| | |
Copies characters in-places instead. Related #27827
|
| |
| |
| |
| | |
ref https://github.com/neovim/neovim/pull/28432
ref https://github.com/neovim/neovim/issues/28469
|