0
0
mirror of https://github.com/vim/vim.git synced 2025-10-19 08:04:27 -04:00
Commit Graph

22332 Commits

Author SHA1 Message Date
zeertzjq
4edaf89233 runtime(doc): improve preinserted() doc
Change the second "if" to "because", otherwise it may be misinterpreted
that preinserted() can return non-zero just because these options are
set.

closes: #18409

Signed-off-by: zeertzjq <zeertzjq@outlook.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-09-27 12:17:09 +00:00
Girish Palya
c05335082a patch 9.1.1797: completion: autocompletion can be improved
Problem:  completion: autocompletion can be improved
Solution: Add support for "longest" and "preinsert" in 'autocomplete';
          add preinserted() (Girish Palya)

* Add support for "longest" in 'completeopt' when 'autocomplete'
  is enabled. (Note: the cursor position does not change automatically
  when 'autocomplete' is enabled.)
* Add support for "preinsert" when 'autocomplete' is enabled. Ensure
  "preinsert" works the same with and without 'autocomplete'
* introduce the preinserted() Vim script function, useful for defining
  custom key mappings.

fixes: #18314
closes: #18387

Signed-off-by: Girish Palya <girishji@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
v9.1.1797
2025-09-26 17:29:38 +00:00
zeertzjq
3fc1f2a00e patch 9.1.1796: Wrong cursor position with wrapped "after" virtual text and 'sbr'
Problem:  Wrong cursor position with wrapped "after" virtual text and
          'showbreak' (Ben Jackson)
Solution: Count size of 'showbreak' in wrapped "after" virtual text in
          line size (zeertzjq).

fixes: #18398
closes: #18400

Signed-off-by: zeertzjq <zeertzjq@outlook.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
v9.1.1796
2025-09-26 17:00:10 +00:00
Christian Brabandt
4aa4a56909 runtime(doc): update getwininfo() documentation about popups
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-09-26 12:57:05 -04:00
Yegappan Lakshmanan
773054b976 patch 9.1.1795: Vim9: popup_show() may return void
Problem:  Vim9: popup_show() may return void
Solution: Modify popup_show() to return -1 for an invalid popup window
          id (Yegappan Lakshmanan).

fixes: #18389
closes: #18401

Signed-off-by: Yegappan Lakshmanan <yegappan@yahoo.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
v9.1.1795
2025-09-26 16:30:52 +00:00
Doug Kearns
7bb733f6bf runtime(vim): Update base syntax, match null_tuple literal
closes: #18404

Signed-off-by: Doug Kearns <dougkearns@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-09-26 16:28:00 +00:00
Christian Brabandt
9cc58faeac patch 9.1.1794: configure: terminfo test does not work with musl
Problem:  configure: terminfo test does not work with musl
          (T3rm1, after v9.9.1.0837)
Solution: include term.h in configure script, add forward declarations,
          in case headers are not found

fixes: #18393
closes: #18405

Signed-off-by: Christian Brabandt <cb@256bit.org>
v9.1.1794
2025-09-26 16:23:06 +00:00
Christian Brabandt
1e009b0634 patch 9.1.1793: Link error when build without channel feature
Problem:  Link error when build without channel feature
          (lindhobe, after v9.1.1774)
Solution: Remove ifdef FEAT_JOB_CHANNEL around
          check_for_string_or_blob_arg()

fixes: #18396

Signed-off-by: Christian Brabandt <cb@256bit.org>
v9.1.1793
2025-09-26 16:18:55 +00:00
Paul Ollis
35a89ce9db patch 9.1.1792: List of changes not protected from changes
Problem:  List of changes not protected from changes when processing
          listeners (after v9.1.1782)
Solution: Fully lock changes list for listener callbacks (Paul Ollis)

closes: #18385

Signed-off-by: Paul Ollis <paul@cleversheep.org>
Signed-off-by: Christian Brabandt <cb@256bit.org>
v9.1.1792
2025-09-25 20:11:34 +00:00
zeertzjq
377339dff3 runtime(doc): make order of verbs match order of operators
related: #18380
closes: #18388

Signed-off-by: zeertzjq <zeertzjq@outlook.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-09-25 20:07:24 +00:00
Christian Brabandt
07c68245de runtime(doc): MS-Windows: Improve documentation about VTP support
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-09-25 20:03:13 +00:00
Yegappan Lakshmanan
f8eda33368 patch 9.1.1791: type(void) throws an internal error
Problem:  type(void) throws an internal error (atitcreate)
Solution: Return proper error message (Yegappan Lakshmanan)

fixes: #17310
closes: #18392

Signed-off-by: Yegappan Lakshmanan <yegappan@yahoo.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
v9.1.1791
2025-09-25 19:21:16 +00:00
Jon Parise
900c747da3 runtime(python): fix 'type' syntax highlighting
The previous patterns unintentionally highlighted words like 'typename'.

addresses: https://github.com/vim/vim/pull/18090#issuecomment-3333025523
closes: #18394

Signed-off-by: Jon Parise <jon@indelible.org>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-09-25 19:08:14 +00:00
zeertzjq
ef818ae444 patch 9.1.1790: completion: Enter does not insert match with "noinsert"
Problem:  completion: Enter does not insert match with "noinsert".
          (Sergey Vlasov)
Solution: Check for compl_shown_match instead of compl_selected_item
          (zeertzjq).

fixes: #18386
related: #1653
closes: #18395

Signed-off-by: zeertzjq <zeertzjq@outlook.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
v9.1.1790
2025-09-25 06:08:04 +00:00
Shay
36544c408e patch 9.1.1789: MS-Windows: using wrong check for bold font
Problem:  MS-Windows: using wrong check for bold font
          (after v9.1.1347)
Solution: Test if lf.lfWeight == FW_BOLD instead of a simple truthiness
          test (Shay)

Commit 411ae58 replaced an operator conditional

`if lf.lfWeight == FW_BOLD`

with a truthiness check

`if lf.lfWeight`

This conditional determines whether `:b` is inserted into the value of
`guifont`. The truthiness check allowed both FW_STANDARD and FW_BOLD
font weights to trigger the insertion of `:b` into the `guifont` string.
This commit restores the `== FW_BOLD` condition.

fixes: #18383
closes: #18397

Signed-off-by: Shay <shay_public@hotmail.com>
Signed-off-by: Hirohito Higashi <h.east.727@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
v9.1.1789
2025-09-25 05:57:11 +00:00
zeertzjq
1ae980a9cb runtime(doc): fix inconsistent indent in cmdline.txt
Also fix typo in autoload/netrw.vim.

related: #18371
closes: #18376

Signed-off-by: Christian Brabandt <cb@256bit.org>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-09-24 18:01:29 +00:00
Doug Kearns
b6f9d38f96 runtime(doc): Improve documentation of the ..= assignment operator
Explicitly mention the "..=" compound assignment operator everywhere
".=" is documented.

Convert some uses of "." and ".=" in the examples to ".." and "..=",
respectively.

closes: #18380

Signed-off-by: Doug Kearns <dougkearns@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-09-24 18:00:16 +00:00
Devin Weaver
4b97fc901f runtime(javascript): Add "using" keyword to JavaScript syntax highlighting
Prior to this change, const and let were keywords for variable
declarations.

This change adds `using` as another keyword for variable declaration.

This JavaScript feature was recently introduced.

Docs:
https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Statements/using

closes: #18381

Signed-off-by: Devin Weaver <suki@tritarget.org>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-09-24 17:56:00 +00:00
Yegappan Lakshmanan
7376fa3fd8 patch 9.1.1788: Vim9: can declare a void variable
Problem:  Vim9: can declare a void variable (Ernie Rael)
Solution: Disallow such variable declaration (Yegappan Lakshmanan)

fixes: #13773
closes: #18382

Signed-off-by: Yegappan Lakshmanan <yegappan@yahoo.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
v9.1.1788
2025-09-24 17:51:17 +00:00
Christian Brabandt
a7680a1a69 runtime(doc): mention improved rendering with 'termguicolors'
related: #9715

Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-09-24 17:43:15 +00:00
Felix Pehla
20e78ee807 runtime(swayconfig): support new config options in syntax script
From sway(5):
 - allow_tearing
 - primary_selection
 - swaybg_command
 - swaynag_command

From sway-output(5):
 - color_profile
 - allow_tearing

From sway-input(5):
 - clickfinger_button_map
 - rotation_angle
 - scroll_button_lock

closes: #18293

Signed-off-by: Felix Pehla <29adc1fd92@gmail.com>
Signed-off-by: James Eapen <james.eapen@vai.org>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-09-23 20:31:18 +00:00
Felix Pehla
24f0dbba8c patch 9.1.1787: filetype: not all Sway config files are recognized
Problem:  filetype: not all Sway config files are recognized
Solution: Detect files within */sway/config.d/* as swayconfig filetype
          (Felix Pehla).

Sways default config automatically includes files placed in
@sysconfdir@/sway/config.d/* (see config.in), so it makes sense to use
the sway syntax for those.

related: #18293

Signed-off-by: Felix Pehla <29adc1fd92@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
v9.1.1787
2025-09-23 20:25:11 +00:00
shane.xb.qian
e89efc22be runtime(doc): update Vim policy
closes: #18372

Signed-off-by: shane.xb.qian <shane.qian@foxmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-09-23 20:10:31 +00:00
Ivan Pešić
a5bc3af087 translation(sr): Update Serbian messages translation
closes: #18372

Signed-off-by: Ivan Pešić <27575106+eevan78@users.noreply.github.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-09-23 20:05:15 +00:00
Konfekt
34747a13e0 runtime(doc): update live-grep and fuzzy-file-picker examples
closes: #18371

Signed-off-by: Konfekt <Konfekt@users.noreply.github.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-09-23 19:53:37 +00:00
Bjoern Foersterling
11bde1f169 runtime(sh): refactored sh.vim syntax script
- unified bashStatement, kshStatement and shStatement as much as
  possible
- separated builtin commands from external programs
- cleaned up kornshell flavor logic
- fixed alias syntax highlighting
- added test for bash alias syntax highlighting
- removed daemon keyword

closes: #18355

Signed-off-by: Bjoern Foersterling <bjoern.foersterling@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-09-23 19:48:09 +00:00
Doug Kearns
da5b6007fb runtime(vim): Update base syntax, match :terminal command
Match the full :terminal command syntax.

closes: #18367

Signed-off-by: Doug Kearns <dougkearns@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-09-23 18:31:34 +00:00
Doug Kearns
b1446dfd23 runtime(vim): Update base syntax, match :wincmd
Match the full :wincmd command syntax.

Allow for oneline assignment to Vim9 variables named winc[md].

Fixes #18368.

Signed-off-by: Doug Kearns <dougkearns@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-09-23 18:24:53 +00:00
Ivan Pešić
8b9e687ea1 translation(sr): Update vim-02-beginner.tutor translation
closes: #18374

Signed-off-by: Ivan Pešić <27575106+eevan78@users.noreply.github.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-09-23 18:22:52 +00:00
Ivan Pešić
d0f47cf656 translation(sr): Update vim-01-beginner.tutor translation
Fix some mistakes and update the text

related: #18374

Signed-off-by: Ivan Pešić <27575106+eevan78@users.noreply.github.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-09-23 18:22:00 +00:00
Foxe Chen
01cde7ff4c patch 9.1.1786: Compile error with clipboard
Problem:  Compile error with clipboard
          (lacyggoill, after v9.1.1784)
Solution: Add $WAYLAND_SRC as dependency for clipboard.c in Makefile
          (Foxe Chen)

closes: #18375

Signed-off-by: Foxe Chen <chen.foxe@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
v9.1.1786
2025-09-23 18:15:48 +00:00
Christian Brabandt
58304078ad runtime(netrw): 'equalalways' is not always respected
fixes: #18358

Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-09-23 18:13:28 +00:00
Christ van Willegen
55e6e6bbee patch 9.1.1785: typo in comment in change.c
Problem:  typo in comment in change.c (after v9.1.1782)
Solution: Fix typo in comment in change.c (Christ van Willegen).

Signed-off-by: Christ van Willegen <cvwillegen@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
v9.1.1785
2025-09-22 20:17:53 +00:00
Christian Brabandt
a73963ed8c runtime(doc): fix typo, reorder, mention zip plugin at :h changed-9.2
Co-authored-by: Christ van Willegen <cvwillegen@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-09-22 20:13:29 +00:00
Christian Brabandt
224f8ca769 runtime(doc): clarify 'fileignorecase' option setting
fixes: #18360

Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-09-22 19:36:37 +00:00
Foxe Chen
368710abcf patch 9.1.1784: Wayland code can be improved
Problem:  Wayland code can be improved
Solution: Refactor Wayland Clipboard code (Foxe Chen).

This the second attempt to refactor the Wayland code base:
- Move clipboard code from wayland.c to clipboard.c
- Use C99 bool type
- Properly poll the Wayland display file descriptor
- Instead of checking if the data source is not NULL in order to
  determine if a selection event comes from us, use a special mime type
  to identify selection events coming from ourselves. The problem with
  the previous approach is that race conditions may occur.
- Put the focus stealing code under a new feature "wayland_focus_steal"
- Use ELAPSED_* macros instead of gettimeofday()
- Pass tests
- Reimplement commented out code
- Update docs
- Make Wayland clipboard behaviour more in line with X11 when connection
  is lost
- add missing malloc checks and possible memory leaks + refactored some
  tests.

closes: #18324

Signed-off-by: Foxe Chen <chen.foxe@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
v9.1.1784
2025-09-22 19:09:52 +00:00
Shay
70d745a61b runtime(zip): support PowerShell Core
fixes: #17987
closes: #18345

Signed-off-by: Shay <shay_public@hotmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-09-22 19:02:24 +00:00
zeertzjq
94c128184f patch 9.1.1783: ins_compl_leader() too far away from ins_compl_leader_len()
Problem:  ins_compl_leader() defined too far away from
          ins_compl_leader_len() (after 9.1.1781).
Solution: Move ins_compl_leader() just before ins_compl_leader_len().
          Add missing "static" to eval0_simple_funccal() definition.
          (zeertzjq).

closes: #18364

Signed-off-by: zeertzjq <zeertzjq@outlook.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
v9.1.1783
2025-09-22 18:22:27 +00:00
Paul Ollis
e87d17ecfb patch 9.1.1782: buffer-listener callbacks may not match buffer content
Problem:  buffer-listener callbacks may not match buffer content, since
          they are buffered until the screen is updated.
Solution: Allow to handle buffer-callbacks un-buffered, meaning to
          handle those changes as soon as they happen (Paul Ollis).

fixes: #18183
closes: #18295

Signed-off-by: Paul Ollis <paul@cleversheep.org>
Signed-off-by: Christian Brabandt <cb@256bit.org>
v9.1.1782
2025-09-21 18:53:40 +00:00
Yegappan Lakshmanan
3a6cf6d53b patch 9.1.1781: some functions could be defined static
Problem:  some functions could be defined static
Solution: Change function definitions and make them static
          (Yegappan Lakshmanan)

closes: #18354

Signed-off-by: Yegappan Lakshmanan <yegappan@yahoo.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
v9.1.1781
2025-09-21 17:52:42 +00:00
Jon Parise
7b973492ae runtime(vimgoto): recognize 'silent' prefixes
It's common to optionally prefix commands like 'packadd!' with
'silent!', but that wasn't recognized by these patterns.

This change adds 'silent' support to the 'packadd', 'runtime', and
'colorscheme' command patterns.

closes: #18361

Signed-off-by: Jon Parise <jon@indelible.org>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-09-21 17:51:00 +00:00
Yuta Yamamoto
9fa8a114b2 patch 9.1.1780: mbyte contains overlapping list of utf_classes table
Problem:  mbyte contains overlapping list of utf_classes table
Solution: Update table to contain non-overlapping list (Yuta Yamamoto)

closes: #18362

Signed-off-by: Yuta Yamamoto <jichael.y.yuta1995@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
v9.1.1780
2025-09-21 17:26:48 +00:00
Christian Brabandt
35531de588 runtime(unicode): update check for netrw
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-09-21 17:25:12 +00:00
Girish Palya
0208b3e80a patch 9.1.1779: completion: 'autocomplete' cannot be enabled per buffer
Problem:  completion: 'autocomplete' cannot be enabled per buffer
          (Tomasz N)
Solution: Make 'autocomplete' global or local to buffer (Girish Palya)

fixes: #18320
closes: #18333

Signed-off-by: Girish Palya <girishji@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
v9.1.1779
2025-09-20 14:54:27 +00:00
zeertzjq
2f3b7ea19a patch 9.1.1778: sha256() treats empty blob and null blob differently
Problem:  sha256() treats empty blob and null blob differently
          (after 9.1.1774).
Solution: Handle null blob the same as empty blob (zeertzjq).

closes: #18341

Signed-off-by: zeertzjq <zeertzjq@outlook.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
v9.1.1778
2025-09-20 14:37:40 +00:00
Andis Spriņķis
841becdc2d runtime(lf): update syntax to support lf version r38
Adds the lf release 38 specific syntax highlighting changes.

From the PR andis-sprinkis/lf-vim#24 by @CatsDeservePets

closes: #18342

Signed-off-by: Andis Spriņķis <andis@sprinkis.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-09-20 14:36:03 +00:00
zeertzjq
8b5fe7d090 patch 9.1.1777: Mouse click to open fold doesn't work with utf-8 "foldclose" chars
Problem:  Mouse click to open fold doesn't work with utf-8 "foldclose"
          chars (Balki)
Solution: Use ScreenLinesUC[off] if it is set (zeertzjq).

fixes: #18344
closes: #18349

Signed-off-by: zeertzjq <zeertzjq@outlook.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
v9.1.1777
2025-09-20 14:16:57 +00:00
zeertzjq
e19a882ffc patch 9.1.1776: completion: "adding" expansion doesn't work with cfc=keyword
Problem:  "adding" expansion doesn't work with cfc=keyword.
Solution: Remove incorrect assignment to compl_cont_status. Don't use
          fuzzy collection in "adding" status (zeertzjq).

related: neovim/neovim#35842
closes: #18351

Signed-off-by: zeertzjq <zeertzjq@outlook.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
v9.1.1776
2025-09-20 14:12:14 +00:00
Damien Lejay
e39d35a44d Remove dlejay from maintainer list
closes: #18352

Signed-off-by: Damien Lejay <damien@lejay.be>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-09-20 14:08:50 +00:00
Samuel Huang
21a21eafec patch 9.1.1775: filetype: Mamba configuration files are not recognized
Problem:  filetype: Mamba configuration files are not recognized
Solution: Detect .mambarc and mambarc as yaml filetype (Samuel Huang).

References:
- https://mamba.readthedocs.io/en/latest/user_guide/configuration.html

closes: #18338

Signed-off-by: Samuel Huang <hi@sgh.ng>
Signed-off-by: Christian Brabandt <cb@256bit.org>
v9.1.1775
2025-09-18 20:28:53 +00:00