robin/laufey

git clone https://git.robinwobin.dev/robin/laufey

robinmerge: 1dc9728daa1d8a2702

master
27.4 KiB611 linesraw
1*news.txt*    Nvim
2
3
4                            NVIM REFERENCE MANUAL
5
6
7Notable changes since Nvim 0.12                                 *news*
8
9For changes in the previous release, see |news-0.12|.
10
11                                       Type |gO| to see the table of contents.
12
13==============================================================================
14BREAKING CHANGES IN HEAD OR EXPERIMENTAL                    *news-breaking-dev*
15
16              ====== Remove this section before release. ======
17
18The following changes to UNRELEASED features were made during the development
19cycle (Nvim HEAD, the "master" branch).
20
21EVENTS
22
23• todo
24
25EXPERIMENTS
26
27• todo
28
29LSP
30
31• todo
32
33LUA
34
35• vim.pos, vim.range always require the `buf` parameter.
36• range.cursor() and range.to_cursor() are removed.
37  Use range.mark() and range.to_mark() instead.
38• pos.to_cursor() returns a (`row,` `col)` tuple
39  instead of returning them as separate values.
40• Renamed current_level param of vim.log.new().
41• `vim.opt.{option}:get()` has improved structure for dict-like options.
42  Some shapes changed:
43  - "key:value" list options (e.g. 'diffopt', 'mousescroll') return a map
44    `{ key = value }` instead of an array of `"key:value"` strings.
45  - The `,,` literal-comma convention (e.g. 'isfname') is not reconstructed in
46    the structured view; the raw string value is unchanged.
47
48DIAGNOSTICS
49
50• todo
51
52OPTIONS
53
54• When |ui2| is enabled, since the ruler is no longer a left-aligned box of
55  fixed width, there is no longer an inconsistent special handling of item
56  groups in 'rulerformat' to configure that fixed width. An old-style left-
57  aligned fixed-width ruler can now be achieved by using item groups exactly
58  as they are documented, e.g. `%-20.20(...%)`.
59
60TREESITTER
61
62• todo
63
64UI
65
66• Healthchecks for |vim.ui.img| were moved to `:checkhealth vim.health`.
67• |ui2| messages pager no longer uses <CR> by default; use |g<| or set
68  'messagesopt' "pager", e.g. `:set messagesopt+=pager:<CR>`.
69• |ui2| `cfg.pager_char` and `cfg.msg.msg.timeout` were replaced by the
70  'messagesopt' items "pager" and "timeout".
71
72VIMSCRIPT
73
74• todo
75
76
77==============================================================================
78BREAKING CHANGES                                                *news-breaking*
79
80These changes may require adaptations in your config or plugins.
81
82API
83
84• API results containing a Lua function reference (e.g. a "callback" reported
85  by |nvim_get_keymap()| or |nvim_get_autocmds()|, or a "callback" option
86  value) are serialized over RPC as a human-readable `"<Lua …>"` hint string,
87  instead of nil.
88• |nvim_create_autocmd()|, |nvim_exec_autocmds()| and |nvim_clear_autocmds()|
89  no longer treat an empty non-nil pattern as nil.
90• |nvim_clear_autocmds()| no longer treats an empty array event as nil.
91• |vim.o|, |vim.opt|, and |nvim_set_option_value()| expand `~` and environment
92  variables (|expand-env|).
93
94DIAGNOSTICS
95
96• `vim.diagnostic.Opts.Status.format` no longer accepts the table mapping
97  from severity to text. Use `vim.diagnostic.Opts.Signs.text` instead.
98• `current_line` property of |vim.diagnostic.Opts.VirtualLines| and
99  |vim.diagnostic.Opts.VirtualText| is now applied on |CursorHold| event.
100  Make sure your 'updatetime' is reasonable.
101
102EDITOR
103
104• Interactive |Ex-mode| (|:exmode|, `nvim -e`) is a persistent |cmdwin|. This is much
105  more flexible and makes "Ex mode" more useful as a kind of "cmdline REPL",
106  with the tradeoff of dropping some POSIX Ex-mode quirks.
107  • |mode()| returns "n" or "i"; "cv" indicates |-es| (script mode) only.
108  • Ex mode is entered with "1q:" or |:exmode|, not "gQ".
109  • ":global/pat/visual" no longer switches to Normal mode per matching line.
110• Non-interactive Ex-mode (|-es|, "script mode") executes stdin as Ex commands
111  directly. It is a "script host", not "POSIX Ex mode".
112  • Output ends with a final newline.
113  • |:visual| is |:edit|: it does not switch to reading stdin as Normal-mode
114    commands, and ":global/pat/visual" does not enter Normal mode per
115    matching line.
116  • Commands that wait for typed input (|input()|, |getchar()|, …) stop Nvim
117    at end-of-input instead of consuming the next stdin line.
118  • An empty line is a no-op instead of advancing the cursor (or failing
119    with |E501| at end-of-file).
120• On Windows, the |trust| db now stores paths with "/" slashes. This means the
121  trust store will be reset (one time).
122• `stdpath("log")` moved to `stdpath("state")/logs`.
123• An operator on a target that creates a Visual selection ("cgn") does not
124  change |'<| |'>|. |gv|
125• |cmdwin| (|q:|, |q/|, |q?|, |c_CTRL-F|):
126  • Only supports one "cmdline level", not "infinite recursion".
127  • Expr-register (|i_CTRL-R_=|, |c_CTRL-R_=|) no longer supports opening
128    cmdwin via |c_CTRL-F|.
129• Behavior of |:restart| changed. Use "!" (|:restart!|) to get the old behavior.
130  • |ZR| now performs |:restart|. Add a count to change the behavior.
131• |ins-repeat| replays the full Insert session, including cursor-moves.
132  Undo and |quote.| still restart at each cursor-move. Use |i_CTRL-O| to get
133  the old behavior: >vim
134    inoremap <Left>  <C-o><Left>
135    inoremap <Right> <C-o><Right>
136• |visual-repeat| is "semantic" instead of "fixed-size". See
137  |visual-fixed-size| if you prefer Vim's "fixed-size" Visual-repeat.
138• |:diffget|, |:diffput| (|do|, |dp|) can be |.| repeated.
139• |Q| adds a |multicursor| instead of replaying the last recorded register.
140  To get the old behavior: >lua
141    vim.keymap.set('n', 'Q', function()
142      local reg = vim.fn.reg_recorded()
143      return reg == '' and '' or ('@' .. reg)
144    end, { expr = true })
145<
146
147EVENTS
148
149• |vim.on_key()| callbacks are not invoked for keys consumed by |getchar()|.
150• |BufModifiedSet| has been removed. Use the |OptionSet| event with pattern
151  "modified" instead.
152• |ui-messages| `msg_show.bufwrite` and `msg_show.completion` messages are now
153  `msg_show.progress` events.
154
155LSP
156
157• `vim.lsp.ClientConfig.cmd` given as a string array now uses
158  `vim.lsp.ClientConfig.root_dir` as its default process working directory.
159• `client.attached_buffers[buf]` now stores `languageId` string (was boolean).
160
161LUA
162
163• "standalone" Lua interpreter mode `nvim -ll` was removed. Use |-l| script
164  mode instead.
165• |vim.opt| no longer supports chaining multiple infix operators (e.g.
166  `vim.opt.wildignore + '*.o' + '*.obj'`). Instead, use tables:
167  `vim.opt.wildignore + {'*.o', '*.obj'}`
168
169OPTIONS
170
171• The 'statusline' `%=` item is no longer ignored in item groups. It applies
172  to the containing item group and its `minwid`.
173  An `%<` item inside an item group now only applies to the containing group
174  and its `maxwid`. Therefore, multiple `%<` can now be effective.
175  The default truncation of item groups is now at the first contained item.
176  To restore the previous truncation from the left, add a `%<` to the start.
177  The same applies to 'rulerformat', 'statuscolumn', 'tabline', 'winbar',
178  'titlestring', and 'iconstring'.
179• 'rulerformat' can no longer be set empty, the new default expression will be
180  restored instead.
181
182PLUGINS
183
184• todo
185
186TREESITTER
187
188• todo
189
190UI
191
192• The bottom right cell of the screen is no longer left empty when the ruler
193  is shown. This was originally intended to prevent unwanted scrolling on
194  quirky terminals.
195
196VIMSCRIPT
197
198• Removed: ctxget(), ctxpop(), ctxpush(), ctxset(), ctxsize(). Use
199  |nvim_get_context()| and |nvim_load_context()| instead.
200
201==============================================================================
202NEW FEATURES                                                    *news-features*
203
204The following new features were added.
205
206API
207
208• |nvim_win_resize()| resizes a window with a specified anchor edge.
209  |nvim_win_set_height()| and |nvim_win_set_width()| are now deprecated.
210• |api-contract| treats `opts` and any parameters thereafter, as optional
211  (equivalent to passing an empty dict). Clients may omit such optional
212  parameters.
213  • The Lua |vim.api| bridge is also a "client" and thus may omit `opts` and
214    any following parameters: >lua
215    -- Before:
216    vim.print(vim.api.nvim_get_mark('A', {}))
217    -- After:
218    vim.print(vim.api.nvim_get_mark('A'))
219• |nvim_buf_call()| and |nvim_win_call()| now preserve multiple return values.
220• |nvim_del_keymap()|, |nvim_buf_del_keymap()| and |vim.keymap.del()| can
221  match only {lhs}, not {rhs}, with `opts.lhs=true`.
222• |nvim_set_hl()| supports "font" key.
223• |nvim_open_win()| `zindex` controls whether the UI will use a dimmed cursor
224  shape when an unfocused float is on top of the cursor.
225• |nvim_echo()| distinguishes zero percent from omitted percent for Progress
226  events.
227• |nvim_create_user_command()| accepts `desc` for Vimscript commands.
228• Support for tabpage-local options ('cmdheight'):
229  • |gettabvar()|
230  • |gettabwinvar()|
231  • |nvim_get_option_info2()|
232  • |nvim_get_option_value()|
233  • |nvim_set_option_value()|
234• |nvim_buf_set_extmark()| `virt_lines_overflow` accepts "wrap" to enable
235  wrapping onto extra rows and "auto" which enables horizontal scrolling when
236  'nowrap' is set and wrapping when 'wrap' is set.
237• |nvim_buf_set_extmark()|  `virt_lines` can extend the last `hl` in each `virt_line`
238  till the end of the line.
239• |nvim_set_option_value()| accepts a new `operation` field to modify the
240  existing option value.
241• |nvim_set_option_value()| returns the new option value.
242• |nvim_create_autocmd()| is now |api-fast|, so it can be called from a fast
243  event context (e.g. |vim.uv| callbacks).
244• |nvim_create_autocmd()| callback |event-args| provide `win`.
245
246BUILD
247
248• Building using "zig build" requires zig 0.16.x.
249• zig build: "-Dcross" option was removed. Often cross-compilation is now
250  detected, so e.g. from a linux host: >
251   zig build -Dtarget=aarch64-macos
252<  will automatically compile a host Lua for use during build.
253• zig build: The new "-Dhost={target_string}" option can be used to override
254  the used host. Use "-Dhost=native" to force cross-compiling or "-Dhost="
255  (empty string) to assume that target binaries can run on the host during the
256  build process (e.g. if target is x86 on a x86_64 system, or if emulation set
257  up with binfmt or similar).
258• zig build: Nvim can now be built to produce a WebAssembly binary via
259  "-Dtarget=wasm32-emscripten", which can run inside a web browser. A basic
260  browser-based demo for running it is also included. Still very
261  experimental.
262
263DEFAULTS
264
265• 'rulerformat' default is exposed as a statusline expression (previously it
266  was implemented as an internal C routine).
267
268DIAGNOSTICS
269
270• |vim.diagnostic.status()| uses the severity names defined by the `signs`
271  field of |vim.diagnostic.config()|, if any.
272• `virtual_lines.overflow` in |vim.diagnostic.config()| controls
273  how virtual lines wider than the window are displayed.
274
275EDITOR
276
277• Multiple cursors (|multicursor|): edit in many places at once.
278  • Toggle cursors with |Q|, |<C-LeftMouse>|, or via API (the
279    "nvim.multicursor" extmarks namespace).
280  • Toggle "follow mode" with |q=|.
281  • Clear cursors with |CTRL-L|, restore them with |gQ|.
282  • |zq| places a cursor at all targets of a motion. E.g. "zqgn" places at
283    every match (and "gv" selects the matches), "Vzqw" places at every
284    Visual-selected word.
285• |:bcd| sets a buffer-local directory. |getcwd()| and |haslocaldir()| take
286  `bufnr` as a third parameter.
287• |:lcd!| |:tcd!| |:bcd!| unsets the directory of that scope.
288• |:command-completion-customlist| can return a list of dictionaries with
289  kind/menu/info/abbr for the popup menu.
290• |cmdwin| (|q:|, |q/|, |q?|, |c_CTRL-F|) is implemented as a "normal"
291  buffer+window instead of a nested-state modal loop:
292  • You can create/navigate windows/tabpages while cmdwin is active. Chaos!
293  • 'inccommand' works in cmdwin!
294  • API calls (e.g. |nvim_buf_delete()|) that previously failed with
295    "E11: Invalid in command-line window" while cmdwin was open, now work
296    normally. Async plugins no longer need special |CmdwinLeave| workarounds.
297  • The |cmdwin-char| is shown via 'statuscolumn'.
298• |gf| and |<cfile>| support `file://…` URIs.
299• |:log| opens log files.
300• |:marks| can list |extmarks| for a given |namespace|.
301• |:marks| gained tab-completion.
302• |:restart| saves/restores the current session (window layout, buffers, …).
303  • |:restart!| (with a bang "!") does not save/restore the session.
304• |ZR| restarts Nvim (|:restart|).
305• |:detach| with range "%" detaches all UIs except the current one.
306• |:detach!| (with bang "!") marks the current UI as detachable: Nvim will
307  continue running if the UI disconnects unexpectedly (e.g. if you
308  accidentally close your terminal, ssh connection lost, etc.).
309  Use |:connect| to reattach.
310• |:uptime| displays uptime.
311• |:packupdate| and |:packdel| for managing |vim.pack|.
312• 'scrollback' is now also valid in |prompt-buffer| buffers to limit the
313  number of history lines kept above the prompt.
314• |v_al| and |v_il| text objects select the whole buffer and the current line
315  without leading or trailing white space.
316• 'autoread' uses file system watchers to detect external changes in
317  real-time, instead of only on |FocusGained| or |:checktime|.
318• During |complete()|-triggered completion, CTRL-N and CTRL-P are now subject
319  to insert-mode mappings.
320• |undo| restores the cursor to its original position ("diw", "atest<Esc>",
321  "d^", …), instead of jumping to the start of the changed text.
322• |undo| no longer restores the old (wrong) position of a mark that you moved
323  (|m|, |:mark|) later. The mark shifts with the text it was moved to, the
324  same as a mark the change never touched.
325• Multibyte characters, translated by 'langmap', now invoke correct
326  mappings.
327  Example: >vim
328    set langmap=õ]
329<    Typing õõ in |Normal-mode| now invokes a mapping bound to ]].
330• New |complete-items| field "commit_chars": characters that accept the
331  selected completion item when typed.
332
333EVENTS
334
335• |:delmarks| now triggers the |MarkSet| autocommand with line==col==0, same
336  as |nvim_buf_del_mark()|
337• |ChanClose| is triggered after a channel is closed, before it is removed.
338• |CmdAtom| fires after each atomic user action (motion, mapping, operator,
339  insert session, visual, Ex command, …).
340• |SessionWritePre| event emits just before |:mksession|.
341• |TextPutPre| and |TextPutPost| are triggered before/after putting text.
342• |TabMoved| is triggered when tabs are reordered.
343• |DirReadPost| is triggered after each |dir| listing is rendered, so it can
344  be sorted or filtered. See |dir-render|.
345
346HIGHLIGHTS
347
348• `Dimmed` for text that should be de-emphasized.
349• |vim.hl.hl_op()| highlights text regions for |TextYankPost| and
350  |TextPutPost| events. It replaces the now deprecated `vim.hl.on_yank()`.
351
352LSP
353
354• LSP capabilities:
355  • Completion supports `CompletionItem.preselect` if 'completeopt' has
356    "preselect". https://microsoft.github.io/language-server-protocol/specification/#completionClientCapabilities
357  • `textDocument/foldingRange` |vim.lsp.foldtext()| highlights collapsed text.
358    https://microsoft.github.io/language-server-protocol/specification/#textDocument_foldingRange
359  • Completion supports `CompletionList.applyKind`: a server can ask for
360    `commitCharacters` and `data` from `itemDefaults` to be merged with the
361    item's own values instead of replacing them.
362    https://microsoft.github.io/language-server-protocol/specification/#completionItemApplyKinds
363  • Completion supports a `completionProvider` registered with
364    `client/registerCapability` instead of declared at `initialize`. Nvim does
365    not advertise `completion.dynamicRegistration` by default; set it in
366    |vim.lsp.Config| `capabilities` to opt in.
367    https://microsoft.github.io/language-server-protocol/specification/#client_registerCapability
368• `:checkhealth vim.lsp` highlights the "current buffer".
369• |vim.lsp.buf.declaration()|, |vim.lsp.buf.definition()|,
370  |vim.lsp.buf.type_definition()|, and |vim.lsp.buf.implementation()|
371  now follows 'switchbuf'.
372• |vim.lsp.buf.declaration()|, |vim.lsp.buf.definition()|,
373  |vim.lsp.buf.type_definition()|, and |vim.lsp.buf.implementation()|
374  now supports passing arbitrary positions.
375• Support for nested snippets.
376• |lsp-completion| supports `commitCharacters`: typing a commit character
377  while a completion item is selected accepts the item as with
378  |complete_CTRL-Y|, then inserts the character. Previously
379  `commitCharacters` had no effect.
380• The `reuse_client` predicate now passes the target buffer. See |vim.lsp.Config| and
381  |vim.lsp.start()|
382• |vim.lsp.formatexpr()| now falls back to `textDocument/formatting` if the whole
383  buffer is being formatted and the language server doesn't support
384  `textDocument/rangeFormatting`.
385• |vim.lsp.buf.format()| respects an explicit `timeout_ms` with `async=true`.
386  The timeout applies per client. Async requests have no timeout when the
387  option is omitted.
388• Support for `workspace/foldingRange/refresh`:
389  https://microsoft.github.io/language-server-protocol/specifications/lsp/3.18/specification/#workspace_foldingRange_refresh
390
391LUA
392
393• |lua-async|: `vim.async` provides structured concurrency primitives for Lua
394  code, including task handles, await helpers, cooperative cancellation,
395  completion-order iteration, and semaphores.
396• |vim.ui.img| can display images. Use `:checkhealth vim.health` to confirm
397  your terminal supports it.
398• |vim.net.request()| can specify custom headers by passing `opts.headers`.
399• |vim.net.request()| can now accept  `method` param overload for multiple HTTP methods.
400• |writefile()| treats Lua and RPC strings as |Blob|, so it can be used to
401  write binary data.
402• |vim.fs.abspath()| gained `cwd` and `plain` parameters.
403• |vim.fs.dir()| with `opts.err=true`, reports errors. An inaccessible root
404  dir yields a single (name, nil, err) item.
405• |vim.fs.dir()| gained a `plain` parameter.
406• |vim.fs.find()| returns a list of errors as its second return value.
407• |vim.fs.mkdir()| creates directories, including parent directories with
408  `opts.parents=true`.
409• |vim.fs.slug()| generates a filesystem-safe file name from an arbitrary
410  identity string, with an optional length bound.
411• |vim.filetype.inspect()| returns a copy of the internal tables used for
412  filetype detection.
413• Added `__eq` metamethod to |vim.VersionRange|. 2 distinct but representing
414  the same range instances now compare equal.
415• Documentation for |vim.fn| now points to preferred Lua alternatives when
416  available.
417• |vim.list.unique()| and |vim.list.bisect()| now support passing a string
418  as a shorthand of a `key`
419• |vim.isnil()| tests if a value is `nil` or |vim.NIL|.
420• |vim.nonnil()| returns the first argument which is not nil.
421• |vim.npcall()| calls the function `fn` in protected-mode like |pcall()|,
422  but returns `nil` on error.
423• |vim.pos| can now convert between positions and buffer offsets.
424• |vim.pos| and |vim.range| can now convert between mark positions.
425• |vim.pos.cursor()| without arguments returns the cursor position of the
426  current window.
427• |vim.ui.input()| now allows setting input scope.
428• |vim.log| provides a logging interface.
429• |vim.pack.get()| output includes revision of a pending update.
430• |vim.pack.get()| can fetch new updates before computing the output.
431• |vim.pack| supports |vim.pack-manifest| of plugins.
432• |vim.o| now accepts table style values for assignment.
433• |vim.keycode()| returns structured info as return value 2.
434• |Iter:count()| counts items in the iterator.
435
436OPTIONS
437
438• Lua functions/closures can be assigned to "func" and "expr" options:
439  |option-value-function| (e.g. `vim.o.operatorfunc`), |expr-option-function|
440  (e.g. `vim.wo.foldexpr`, `vim.bo.indentexpr`). Reading such an option:
441  • ...from Lua, gets the function itself.
442  • ...from Vimscript/RPC, gets a human-readable `"<Lua …>"` hint string.
443• 'ttyfast' can be disabled during startup by setting |$NVIM_NOTTYFAST|.
444• 'scrolloffpad' allows vertically centering cursor at the end of file.
445• 'shortmess' flag |shm-u| silences undo/redo messages.
446• 'statusline' supports |stl-%0{| to insert the expression result verbatim.
447  The `%=` item is supported within item groups to separate alignment sections
448  within the containing group until its `minwid` is reached. The truncation
449  of an item group to its `maxwid` can be controlled with the `%<` item.
450  The new %#(...%#) item denotes a highlight scope.
451  The same applies to 'rulerformat', 'statuscolumn', 'tabline', 'winbar',
452  'titlestring', and 'iconstring'.
453• 'winpinned' prevents window from closing unless specifically targeted.
454• 'packlockfile' sets the path used for |vim.pack-lockfile|.
455• 'previewpopup' decides how the preview window is displayed.
456• 'messagesopt' items "pager" and "timeout" configure the |ui2| message pager
457  key and how long a message stays in the message window.
458
459PERFORMANCE
460
461• LSP shares identical file watcher registrations, reducing startup work in
462  large workspaces.
463• |treesitter-highlight| performance on large injection-heavy files improves
464  by 50% to 100% by reusing edited child-tree ranges.
465• Nvim architecture allows pure-Lua implementations of some `vim.fn`
466  functions, which skips the Vimscript <=> Lua "bridge" (no data
467  conversion/marshalling) entirely, if the `vim.fn` function is called from
468  Lua.
469• Internal LSP data is cleared using `table.clear`, which reduces GC and
470  memory reallocation during each data reset.
471• RPC client avoids string allocations when parsing Content-Length messages.
472• LSP: "overscan" semantic_token range requests to avoid flicker.
473• |vim.hl.range()| and |vim.hl.hl_op()| are faster for large characterwise and
474  linewise regions.
475• The display of multibyte text with grapheme clusters has been optimized,
476  by calculating byte length and cell width of clusters in a single loop.
477
478PLUGINS
479
480• The zip plugin is now |zip|, a read-only archive browser built on |dir|.
481  To use the legacy plugin instead: >
482  :packadd old-zip
483<
484• provider: add bun support for Node.js plugins
485
486STARTUP
487
488• todo
489
490TERMINAL
491
492• todo
493
494TREESITTER
495
496• |vim.treesitter.get_captures()| returns highlight captures at a given position,
497  on a whole line, or overlapping a range. It replaces
498  |vim.treesitter.get_captures_at_pos()|.
499• |v_]N| |v_[N| expand selection to sibling treesitter node.
500• |treesitter-highlight-conceal| can be removed by adding a `@noconceal`
501  capture.
502• |vim.treesitter.select()| starts or adjusts a visual selection at cursor,
503  based on tree nodes.
504• The `diff` treesitter parser is bundled.
505
506TUI
507
508• The TUI will re-query the terminal's background color when resuming from
509  a suspended state, and Nvim will update 'background' accordingly.
510• User can override the builtin "terminfo" via |$NVIM_TERMDEFS|. This is
511  similar to Vim's |t_xx| options.
512
513UI
514
515• |:checkhealth| shows filewatcher info in the Performance section.
516• Floating window border highlights (|hl-FloatBorder|, |hl-FloatTitle|,
517  |hl-FloatFooter|) combine with the window-local |hl-Normal| background
518  instead of falling back to the global background.
519• These builtin "picker" menus delegate to |vim.ui.select()|:
520  • :browse oldfiles
521  • |:recover|
522  • |:tselect|
523  • |z=| (spell suggest)
524• The |ui2| dialog window scrolls with the mouse wheel, by 'mousescroll'
525  lines.
526• The |ui2| `[+x]` "spill" indicator is highlighted with |hl-MoreMsg|.
527
528VIMSCRIPT
529
530• `fnamemodify(':h')` preserves logical roots for more path formats.
531• |v:exitreason| is set before |QuitPre|.
532• |v:startreason| indicates whether Nvim started normally or by |:restart|.
533• |v:starttime| is the process start time (nanoseconds since UNIX epoch).
534• |v:useractive| indicates user activity.
535• |serverlist()| with `info=true` returns details for each server (own + peers).
536• These Vimscript functions may be called from |api-fast| context (e.g.
537  |vim.uv| timer/handle callbacks): |keytrans()|, |char2nr()|, |nr2char()|,
538  |str2list()|, |strpart()|, |strcharpart()|, |strgetchar()|, |strchars()|,
539  |strcharlen()|, |strlen()|, |strdisplaywidth()|, |byteidx()|, |charidx()|,
540  |utf16idx()|, |tr()|, |trim()|.
541
542==============================================================================
543CHANGED FEATURES                                                 *news-changed*
544
545These existing features changed their behavior.
546
547• `nvim_exec_autocmds({buf=…})` runs in the context of the target buffer.
548• |SessionLoadPost| is no longer included in views saved by |:mkview|.
549• |OptionSet| is no longer triggered during startup by automatic
550  |'background'| detection.
551• |SessionWritePre| and |SessionWritePost| are no longer triggered by
552  |:mkview|, |:mkvimrc|, or |:mkexrc|.
553• Editing a local directory now shows its contents in a `filetype=directory`
554  buffer. See |dir|.
555• |:Open| with no arguments uses the current file.
556• The "buffer" key was renamed to "buf" in these functions (but the old name
557  "buffer" is still accepted, for backwards compatibility):
558  • |nvim_clear_autocmds()|
559  • |nvim_create_autocmd()|
560  • |nvim_exec_autocmds()|
561  • |nvim_get_autocmds()|
562• |vim.keymap.set()| and |vim.keymap.del()| accept a list of strings for `lhs`.
563• 'statuscolumn' click function labels can be different across rows.
564  |v:virtnum| and |v:lnum| are available during the click function callback.
565• Markdown inline highlighting now conceals the backslash in backslash escapes.
566• Markdown inline backslash escapes and hard line breaks no longer use the
567  `@string.escape` capture.
568• |vim.lsp.util.open_floating_preview()| windows (e.g. |vim.lsp.buf.hover()|)
569  converted to normal windows (e.g. with |CTRL-W_H|) are no longer closed
570  automatically.
571• |vim.fs.normalize()| `opts.expand_env=false` key was renamed to
572  `opts.plain=true` and now does not expand leading tildes ("~") in addition
573  to environment variables ("expand_env" is still accepted, for backwards
574  compatibility).
575• |:helptags| finds help tags with the "vimdoc" |treesitter| parser (and thus
576  requires it to be installed).
577• `:helptags ALL` reports |E152| for "doc" directories it cannot write,
578  instead of silently skipping them.
579• The highlighting groups |hl-CursorLineFold| and |hl-CursorLineSign| are
580  always used when 'cursorline' is set.
581• |vim.lsp.util.apply_text_edits()| accepts `opts.keep_cursor`, to hold the
582  cursor on the text it is on while edits move around it.
583• 'tagfunc' is now also used for :tag completion.
584• Some character clusters are restored to occupy two cells like they
585  did prior to Nvim 0.11. These include Thai syllables like สำ and
586  half-width Katakana with voicing marks ガ. The TUI renders these in
587  a safe way which also supports terminals which consider these to be
588  single-width.
589• in script mode |-l|, |print()| now behaves more similar to standalone
590  lua. Printing is done to stdout, and empty lines are not stripped.
591  No translation of special characters is done, so escape sequences
592  can be used when printing to a terminal.
593
594==============================================================================
595REMOVED FEATURES                                                 *news-removed*
596
597These deprecated features were removed.
598
599• Vimscript functions ctxget(), ctxpop(), ctxpush(), ctxset(), ctxsize()
600  and the "context stack". Use |nvim_get_context()| and |nvim_load_context()|
601  with a script-owned list instead.
602• |vim.lsp.buf.declaration()|, |vim.lsp.buf.definition()|,
603  |vim.lsp.buf.type_definition()|, and |vim.lsp.buf.implementation()|
604  no longer accept the `reuse_win` option.
605
606==============================================================================
607DEPRECATIONS                                                *news-deprecations*
608
609See |deprecated-0.13|.
610
611 vim:tw=78:ts=8:sw=2:et:ft=help:norl: