aboutsummaryrefslogtreecommitdiff
path: root/runtime/doc/news.txt
blob: 0a9b926b7f8be385e3a1590d434f3a7ae0ccf76a (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
*news.txt*    Nvim


                            NVIM REFERENCE MANUAL


Notable changes in Nvim 0.10 from 0.9                                    *news*

For changes in Nvim 0.9, see |news-0.9|.

                                       Type |gO| to see the table of contents.

==============================================================================
BREAKING CHANGES                                                *news-breaking*

The following changes may require adaptations in user config or plugins.

• |vim.tbl_islist()| now checks whether a table is actually list-like (i.e.,
  has integer keys without gaps and starting from 1). For the previous
  behavior (only check for integer keys, allow gaps or not starting with 1),
  use |vim.tbl_isarray()|.

• "#" followed by a digit no longer stands for a function key at the start of
  the lhs of a mapping.

• `:behave` was removed.
  - If you used `:behave xterm`, the following is equivalent: >vim

    set mousemodel=extend
<
  - If you used `:behave mswin`, the following is equivalent: >vim

    set selection=exclusive
    set selectmode=mouse,key
    set mousemodel=popup
    set keymodel=startsel,stopsel
<
• When switching windows, |CursorMoved| autocommands trigger when Nvim is back
  in the main loop rather than immediately. This is more compatible with Vim.

• |LspRequest| and LspProgressUpdate (renamed to |LspProgress|) autocmds were
  promoted from a |User| autocmd to first class citizen.

• Renamed `vim.treesitter.playground` to `vim.treesitter.dev`.

• Removed functions from the |vim.json| module:
  • Unnecessary, undocumented functions which caused global side-effects.
  • `vim.json.null` is redundant with `vim.NIL`.
  • `vim.json.array_mt` (and related) is redundant with `vim.empty_dict()`.

==============================================================================
NEW FEATURES                                                    *news-features*

The following new APIs and features were added.

• Performance:
  • 'diffopt' "linematch" scoring algorithm now favours larger and less groups
    https://github.com/neovim/neovim/pull/23611

• Added |vim.lsp.status()| to consume the last progress messages as a string.

• Neovim's LSP client now always saves and restores named buffer marks when
  applying text edits.

• Nvim now supports the `positionEncoding` server capability. If a server
  responds with the `positionEncoding` capability in its initialization
  response, Nvim automatically sets the client's `offset_encoding` field.

• Dynamic registration of LSP capabilities. An implication of this change is
  that checking a client's `server_capabilities` is no longer a sufficient
  indicator to see if a server supports a feature. Instead use
  `client.supports_method(<method>)`. It considers both the dynamic
  capabilities and static `server_capabilities`.

• |vim.iter()| provides a generic iterator interface for tables and Lua
  iterators |luaref-in|.

• Added |vim.ringbuf()| to create ring buffers.

• Added |vim.keycode()| for translating keycodes in a string.

• Added |vim.treesitter.query.omnifunc()| for treesitter query files (set by
  default).

• |'smoothscroll'| option to scroll by screen line rather than by text line
  when |'wrap'| is set.

• |Query:iter_matches()| now has the ability to set the maximum start depth
  for matches.

• Added inline virtual text support to |nvim_buf_set_extmark()|.

• The terminal buffer now supports reflow (wrapped lines adapt when the buffer
  is resized horizontally). Note: Lines that are not visible and kept in
  |'scrollback'| are not reflown.

• |vim.system()| for running system commands.

• |nvim_set_keymap()| and |nvim_del_keymap()| now support abbreviations.

• Implemented LSP inlay hints: |vim.lsp.inlay_hint()|
  https://microsoft.github.io/language-server-protocol/specifications/lsp/3.17/specification/#textDocument_inlayHint

==============================================================================
CHANGED FEATURES                                                 *news-changed*

The following changes to existing APIs or features add new behavior.

• |vim.tbl_contains()| now works for general tables and allows specifying a
  predicate function that is checked for each value. (Use |vim.list_contains()|
  for checking list-like tables (integer keys without gaps) for literal values.)

• |vim.region()| can use a string accepted by |getpos()| as position.

• vim.diagnostic.config() now accepts a function for the virtual_text.prefix
  option, which allows for rendering e.g., diagnostic severities differently.

• Defaults:
  • 'shortmess' includes the "C" flag.
  • Automatic linting of treesitter query files (see |ft-query-plugin|).
    Can be disabled via: >lua
      vim.g.query_lint_on = {}
<  • Enabled treesitter highlighting for treesitter query files.

• The `workspace/didChangeWatchedFiles` LSP client capability is now enabled
  by default.

• |LspRequest| autocmd callbacks now contain additional information about the LSP
  request status update that occurred.

• `:source` without arguments treats a buffer with its 'filetype' set to "lua"
  as Lua code regardless of its extension.

• |:checkhealth| buffer now implements |folding|. The initial folding status is
  defined by the 'foldenable' option.

• |:Man| now respects 'wrapmargin'

==============================================================================
REMOVED FEATURES                                                 *news-removed*

The following deprecated functions or APIs were removed.

• Vimball support is removed.
  - :Vimuntar command removed.

==============================================================================
DEPRECATIONS                                                *news-deprecations*

The following functions are now deprecated and will be removed in a future
release.

• Checkhealth functions:
  - |health#report_error|, |vim.health.report_error()|	Use |vim.health.error()| instead.
  - |health#report_info|, |vim.health.report_info()|	Use |vim.health.info()| instead.
  - |health#report_ok|, |vim.health.report_ok()|	Use |vim.health.ok()| instead.
  - |health#report_start|, |vim.health.report_start()|	Use |vim.health.start()| instead.
  - |health#report_warn|, |vim.health.report_warn()|	Use |vim.health.warn()| instead.

• |API| functions:
  - |nvim_buf_get_option()|	Use |nvim_get_option_value()| instead.
  - |nvim_buf_set_option()|	Use |nvim_set_option_value()| instead.
  - |nvim_get_option()|		Use |nvim_get_option_value()| instead.
  - |nvim_set_option()|		Use |nvim_set_option_value()| instead.
  - |nvim_win_get_option()|	Use |nvim_get_option_value()| instead.
  - |nvim_win_set_option()|	Use |nvim_set_option_value()| instead.

• vim.lsp functions:
  - |vim.lsp.util.get_progress_messages()|	Use |vim.lsp.status()| instead.
  - |vim.lsp.for_each_buffer_client()|	  	Use |vim.lsp.get_active_clients()| instead.

• `vim.loop` has been renamed to `vim.uv`.

 vim:tw=78:ts=8:sw=2:et:ft=help:norl: