aboutsummaryrefslogtreecommitdiff
path: root/runtime
Commit message (Collapse)AuthorAge
...
| * docs: various fixes (#27063)dundargoc2024-01-25
| | | | | | | | | | | | Co-authored-by: lmenou <menl94629@gmail.com> Co-authored-by: altermo <107814000+altermo@users.noreply.github.com> Co-authored-by: VanaIgr <vanaigranov@gmail.com> Co-authored-by: Gregory Anders <greg@gpanders.com>
| * feat(ui): add support for OSC 8 hyperlinks (#27109)Gregory Anders2024-01-24
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Extmarks can contain URLs which can then be drawn in any supporting UI. In the TUI, for example, URLs are "drawn" by emitting the OSC 8 control sequence to the TTY. On terminals which support the OSC 8 sequence this will create clickable hyperlinks. URLs are treated as inline highlights in the decoration subsystem, so are included in the `DecorSignHighlight` structure. However, unlike other inline highlights they use allocated memory which must be freed, so they set the `ext` flag in `DecorInline` so that their lifetimes are managed along with other allocated memory like virtual text. The decoration subsystem then adds the URLs as a new highlight attribute. The highlight subsystem maintains a set of unique URLs to avoid duplicating allocations for the same string. To attach a URL to an existing highlight attribute we call `hl_add_url` which finds the URL in the set (allocating and adding it if it does not exist) and sets the `url` highlight attribute to the index of the URL in the set (using an index helps keep the size of the `HlAttrs` struct small). This has the potential to lead to an increase in highlight attributes if a URL is used over a range that contains many different highlight attributes, because now each existing attribute must be combined with the URL. In practice, however, URLs typically span a range containing a single highlight (e.g. link text in Markdown), so this is likely just a pathological edge case. When a new highlight attribute is defined with a URL it is copied to all attached UIs with the `hl_attr_define` UI event. The TUI manages its own set of URLs (just like the highlight subsystem) to minimize allocations. The TUI keeps track of which URL is "active" for the cell it is printing. If no URL is active and a cell containing a URL is printed, the opening OSC 8 sequence is emitted and that URL becomes the actively tracked URL. If the cursor is moved while in the middle of a URL span, we emit the terminating OSC sequence to prevent the hyperlink from spanning multiple lines. This does not support nested hyperlinks, but that is a rare (and, frankly, bizarre) use case. If a valid use case for nested hyperlinks ever presents itself we can address that issue then.
| * vim-patch:a262d3f41bc5Christian Clason2024-01-24
| | | | | | | | | | | | | | | | | | | | | | | | runtime(netrw): Don't change global options (vim/vim#13910) Originally reported at: https://github.com/vim-jp/issues/issues/1428 'isk' was unintentionally changed by netrw, regression introduced in Commit: 71badf9547e8f89571b9a095183671cbb333d528 https://github.com/vim/vim/commit/a262d3f41bc51be697ddebbf04f186e7d193fd6f Co-authored-by: K.Takata <kentkt@csc.jp>
| * vim-patch:e1ddc2d5875dChristian Clason2024-01-24
| | | | | | | | | | | | | | | | | | | | | | | | runtime(fortran): update syntax and documentation (vim/vim#13912) * runtime (doc): update Fortran section * runtime(syntax): Complete support for Fortran 2023. Minor improvements. https://github.com/vim/vim/commit/e1ddc2d5875d820b5dcb1423428ce4a01cce3fda Co-authored-by: Ajit-Thakkar <142174202+Ajit-Thakkar@users.noreply.github.com>
| * refactor: rewrite ruby provider in luadundargoc2024-01-24
| |
| * build: various build improvementsdundargoc2024-01-24
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - remove "ran-" prefix from touch files as it's redundant since the they're already in the directory named `touches`. - Include `contrib` when formatting with `make formatlua`. - Use TARGET_FILE generator expression instead of assuming the executable location. - reuse logic that determines whether to use lua or luajit. - add translations to the `nvim` target. Makefile improvements: - rename variable `CMAKE_PRG` to `CMAKE` to make it more consistent with the builtin `MAKE` variable. - stop propagating flags to generator. Users should use cmake for non-standard use cases. - remove `+` prefix from targets. If the user for whatever reason wants to dry-run a target then they should be able to.
| * fix(treesitter): avoid # of nil in _query_linterDaniel Kongsgaard2024-01-24
| |
| * refactor: rewrite perl provider in luadundargoc2024-01-24
| |
| * fix(spell): always accept ':' as filename char in 'spellfile' (#27172)zeertzjq2024-01-24
| | | | | | Follow-up to #25236
| * vim-patch:ca0e9823a1dfChristian Clason2024-01-24
| | | | | | | | | | | | | | | | | | | | runtime(c): Highlight user defined functions closes: vim/vim#13763 https://github.com/vim/vim/commit/ca0e9823a1dfd71a17c0f08cb7973d413bf98999 Co-authored-by: Luca Saccarola <github.e41mv@aleeas.com>
| * vim-patch:9c5b90db035bChristian Clason2024-01-24
| | | | | | | | | | | | | | | | | | | | runtime(vim): Update syntax file (vim/vim#13906) Highlight :2match and :3match and add these to :help ex-cmd-index. https://github.com/vim/vim/commit/9c5b90db035b0e488f4cc686514a8d2a42265eb2 Co-authored-by: dkearns <dougkearns@gmail.com>
| * vim-patch:50dbe16cd818Christian Clason2024-01-24
| | | | | | | | | | | | | | | | | | | | runtime(qml): Use shiftwidth() in indent plugin (vim/vim#13908) Fixes vim/vim#13907 https://github.com/vim/vim/commit/50dbe16cd8180eb03e8589694b574d610e6d562c Co-authored-by: dkearns <dougkearns@gmail.com>
| * vim-patch:36e2c0f29332Christian Clason2024-01-24
| | | | | | | | | | | | | | | | runtime(mail): updated syntax file https://github.com/vim/vim/commit/36e2c0f29332bd430f03c007be56fc6894f49923 Co-authored-by: GI <gi1242@gmail.com>
| * docs(treesitter): add more examples, and improve consistencyJongwook Choi2024-01-24
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Docs for treesitter would benefit from including more real-world and practical examples of queries and usages, rather than hypothetical ones (e.g. names such as "foo", "bar"). Improved examples should be more user-friendly and clear to understand. In addition, align the capture names in some examples with the actual ones being used in the built-in query files or in the nvim-treesitter plugin, e.g.: - `@parameter` -> `@variable.parameter` - `@comment.doc.java` -> `@comment.documentation.java` - etc.
| * fix(treesitter): prefix treesitter types with vimPhạm Huy Hoàng2024-01-24
| |
| * vim-patch:e13b665a6e2a (#27163)zeertzjq2024-01-24
| | | | | | | | | | | | | | | | runtime(doc): change "VIsual mode" to "Visual mode" in :h SafeState (vim/vim#13901) "Visual mode" is used everywhere else in the help when not referring to something in the source code. https://github.com/vim/vim/commit/e13b665a6e2a32910ff5c3fec330bef4a10f8f23
| * test: typing for screen.luaLewis Russell2024-01-23
| | | | | | | | | | Very rough buts resolves most diagnostic errors and should provide some useful hovers.
| * fix(diagnostic): fix typing on field |diagnostic-severity|Jongwook Choi2024-01-23
| | | | | | | | | | | | | | | | Problem: vim.diagnostic.{underline,float,virtual_text...}.severity will have a type warning on list-like or table (min-max) inputs, e.g. `vim.diagnostic.config { float = { severity = { min = INFO } } }`. Solution: Correct the typing as documented in |diagnostic-severity|.
| * vim-patch:add31baedaf0Christian Clason2024-01-22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | runtime(sh): Add handling for ksh93 shared-state comsubs and mksh valsubs (vim/vim#13884) This commit adds support for ksh93 shared-state command substitutions (syntax: ${ command; }) and mksh's value substitutions (syntax: ${|command;}) in the sh syntax script. Also add a syntax test for ksh subshares with dumps included to make sure it doesn't regress. fixes: vim/vim#9514 https://github.com/vim/vim/commit/add31baedaf03b92dbd41427860c61c639ef705c Co-authored-by: Johnothan King <johnothanking@protonmail.com>
| * vim-patch:3b2c27415d7dChristian Clason2024-01-22
| | | | | | | | | | | | | | | | | | runtime(chuck): include ChucK syntax file (vim/vim#13895) https://github.com/vim/vim/commit/3b2c27415d7d6e97be9580b66528e8c19d19aade Co-authored-by: Andrea C from The App <3269984+gacallea@users.noreply.github.com> Co-authored-by: gacallea <gacallea@users.noreply.github.com>
| * vim-patch:ea9a93e5b098Christian Clason2024-01-22
| | | | | | | | | | | | | | | | | | | | runtime(go): update Go syntax file (vim/vim#13896) Update the Go syntax file with some recent changes made to vim-go. https://github.com/vim/vim/commit/ea9a93e5b0989b9242a1ea1f6f2dd7c9399e6f20 Co-authored-by: Billie Cleek <bhcleek@users.noreply.github.com>
| * refactor: rewrite python provider in luadundargoc2024-01-22
| |
| * docs(options): remove misleading sentence (#27129)zeertzjq2024-01-22
| | | | | | | | Setting 'verbose' to 1 doesn't cause Nvim to produce messages. It adds more information to existing messages, which is documented above.
| * feat(fold): transparent foldtextLewis Russell2024-01-22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 'foldtext' can be set to an empty string to disable and render the line with: - extmark highlight - syntax highlighting - search highlighting - no line wrapping - spelling - conceal - inline virtual text - respects `fillchars:fold` Currently normal virtual text is not displayed Co-authored-by: zeertzjq <zeertzjq@outlook.com>
| * Merge pull request #27076 from glepnir/extmark_hlgroupbfredl2024-01-22
| |\ | | | | | | refactor(api): use hl id directly in nvim_buf_set_extmark
| | * refactor(api): give "hl_group" more accurate _meta typebfredl2024-01-22
| | | | | | | | | | | | | | | These can either be number or string in lua, so we can specify this directly as "number|string".
| | * refactor(api): use hl id directly in nvim_buf_set_extmarkglepnir2024-01-20
| | |
| * | fix(eval): properly support checking v:lua function in exists() (#27124)Raphael2024-01-22
| | |
| * | Merge pull request #26813 from VanaIgr/screen-pos-speedupzeertzjq2024-01-22
| |\ \ | | | | | | | | | | | | | | | | | | | | | | | | perf: make screen size and position calculations more efficient N/A patches for version.c: vim-patch:9.1.0037: Calling get_breakindent_win() repeatedly when computing virtcol vim-patch:9.1.0038: Unnecessary loop in getvcol()
| | * | docs(news): expand the list of performance improvementsVanaIgr2024-01-22
| | |/ | | | | | | | | | | | | | | | | | | | | | When computing on-screen size or position, the size 'breakindent' and 'showbreak' is now cached, and checks for whether a faster character size function can be used are performed only once at the start. Multibyte characters are not decodes multiple times anymore, and character decoding functions are more efficient. Additionally, the amount of trailing spaces for pasted blockwise text is now calculated correctly for multibyte characters. Internal lisp formatting now doesn't erroneously use inline virtual text from a different line.
| * | feat(vim.version): add `vim.version.le` and `vim.version.ge`Jongwook Choi2024-01-21
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - Problem: One cannot easily write something like, for example: `version_current >= {0, 10, 0}`; writing like `not vim.version.lt(version_current, {0, 10, 0})` is verbose. - Solution: add {`le`,`ge`} in addition to {`lt`,`gt`}. - Also improve typing on the operator methods: allow `string` as well. - Update the example in `vim.version.range()` docs: `ge` in place of `gt` better matches the semantics of `range:has`.
| * | vim-patch:27a4632af675Christian Clason2024-01-21
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | runtime(filetype): detect *.ck files as Chuck filetype (vim/vim#13888) closes vim/vim#13886 https://github.com/vim/vim/commit/27a4632af675345f9d3b4f3d66a63756835df8cc Co-authored-by: Christian Brabandt <cb@256bit.org>
| * | feat(treesitter)!: new standard capture namesChristian Clason2024-01-21
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Problem: Sharing queries with upstream and Helix is difficult due to different capture names. Solution: Define and document a new set of standard captures that matches tree-sitter "standard captures" (where defined) and is closer to Helix' Atom-style nested groups. This is a breaking change for colorschemes that defined highlights based on the old captures. On the other hand, the default colorscheme now defines links for all standard captures (not just those used in bundled queries), improving the out-of-the-box experience.
| * | fix(lsp): clean up duplicate and unused meta type annotationsJongwook Choi2024-01-20
| | |
| * | build: create separate targets for nvim with and without runtime filesdundargoc2024-01-20
| | | | | | | | | | | | | | | | | | | | | This distinction is important for correct dependency management, as the nvim binary is used to create some runtime files. The nvim binary (and the target to build it) is thus called `nvim_bin` and the target to build all of nvim (binary+runtime) is called `nvim`.
| * | feat(api): support getting abbreviations (#26868)Raphael2024-01-20
| | |
| * | feat(ui): add chdir UI event (#27093)Gregory Anders2024-01-19
| | | | | | | | | | | | | | | | | | When an embedded Nvim instance changes its current directory a "chdir" UI event is emitted. Attached UIs can use this information however they wish. In the TUI it is used to synchronize the cwd of the TUI process with the cwd of the embedded Nvim process.
| * | fix(vim.deprecate): show deprecation warning in devel versions as wellJongwook Choi2024-01-19
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Problem: On devel(nightly) versions, deprecation warnings for hard-deprecated features are not being displayed. E.g., - to be removed in: 0.11 - hard-deprecation since 0.10 - soft-deprecation since 0.9 then 0.10-nightly (0.10.0-dev) versions as well as 0.10.0 (stable) should display the deprecation warning message. Solution: Improve the code and logic on `vim.deprecate()`, and improve test cases with mocked `vim.version()`.
| * | refactor(lua): refactored globaltermo2024-01-19
| | |
| * | Merge pull request #27061 from luukvbaal/extmarkbfredl2024-01-19
| |\ \ | | |/ | |/| fix(extmarks): do not remove invalid marks from decor upon deletion
| | * docs(extmarks): add undocumented "details" array fieldsLuuk van Baal2024-01-18
| | |
| * | fix(treesitter): validate language alias for injectionsChristian Clason2024-01-18
| | | | | | | | | | | | | | | | | | | | | | | | Problem: Parsed language annotations can be random garbage so `nvim_get_runtime_file` throws an error. Solution: Validate that `alias` is a valid language name before trying to find a parser for it.
| * | docs(vim.iter): correct `bool` to `boolean` (#27018)notomo2024-01-18
| | |
| * | docs: various #25289Justin M. Keyes2024-01-18
| | | | | | | | | | | | | | | | | | Co-authored-by: Jongwook Choi <wookayin@gmail.com> Co-authored-by: Oliver Marriott <hello@omarriott.com> Co-authored-by: Benoit de Chezelles <bew@users.noreply.github.com> Co-authored-by: Jongwook Choi <wookayin@gmail.com>
| * | vim-patch:46d67d22b9baChristian Clason2024-01-18
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | runtime(swayconfig): add focus_follows_mouse and smart_qaps syntax keywords See: https://github.com/swaywm/sway/blob/0aceff74696f03d306dc9de5473d9ed7afb73f67/sway/sway.5.scd?plain=1#L680 `focus_follows_mouse yes|no|always` https://github.com/swaywm/sway/blob/0aceff74696f03d306dc9de5473d9ed7afb73f67/sway/sway.5.scd?plain=1#L770 closes: vim/vim#13797 https://github.com/vim/vim/commit/46d67d22b9baa575de3ef2fb7ff430b11dfa1e26 Co-authored-by: James Eapen <james.eapen@vai.org>
| * | vim-patch:a39af0290496Christian Clason2024-01-18
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | runtime(i3config): remove always from `focus_follows_mouse` The always option does not exist in i3, only sway. From https://i3wm.org/docs/userguide.html: `focus_follows_mouse yes|no` Version number incremented by 2 because the last commit did not increment the version. https://github.com/vim/vim/commit/a39af02904966087b2af2372fa8233c4dfe149e3 Co-authored-by: James Eapen <james.eapen@vai.org>
| * | vim-patch:6e5a6c9965f6Christian Clason2024-01-18
| | | | | | | | | | | | | | | | | | | | | | | | runtime(netrw): minor changes to fix move cmd on windows (vim/vim#13823) https://github.com/vim/vim/commit/6e5a6c9965f667712494ae0a9df8a407267cc72f Co-authored-by: MiguelBarro <45819833+MiguelBarro@users.noreply.github.com>
| * | vim-patch:9.1.0039: too vague errors for 'listchars'/'fillchars' (#27070)zeertzjq2024-01-18
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Problem: too vague errors for 'listchars'/'fillchars' Solution: Include the field name in error message. (zeertzjq) related: #27050 closes: vim/vim#13877 https://github.com/vim/vim/commit/6a8d2e1634f8f0d7463a2786dbcbe0f38dd287a7 Co-authored-by: Cole Frankenhoff <cole.nhf@gmail.com>
| * | fix(lua): return after assert returns assert message (#27064)altermo2024-01-17
| | |
| * | vim-patch:9b03d3e75b42 (#27059)Sean Dewar2024-01-17
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Translate the Vim9 script Godot files to legacy. `<scriptcmd>` is not ported yet, so replace it with `<Cmd>` and `<SID>`. If it's ported, `<scriptcmd>call s:` can be used instead. Includes changes from: vim-patch:0daafaa7d99e (was partial, but is now pretty much fully ported) vim-patch:9712ff1288f9 Co-authored-by: Maxim Kim <habamax@gmail.com>