aboutsummaryrefslogtreecommitdiff
path: root/runtime/lua/vim/_meta/api.lua
diff options
context:
space:
mode:
authorLuuk van Baal <luukvbaal@gmail.com>2025-01-16 18:10:22 +0100
committerluukvbaal <luukvbaal@gmail.com>2025-01-23 10:56:25 +0100
commit34d808b73cbcb0a43636d826282193ab1ca8c148 (patch)
tree1a03834e3651002e92bf3a4732b05c061aa97898 /runtime/lua/vim/_meta/api.lua
parent8634bd46b26f28fa26950128b0cc585560bd6a9a (diff)
downloadrneovim-34d808b73cbcb0a43636d826282193ab1ca8c148.tar.gz
rneovim-34d808b73cbcb0a43636d826282193ab1ca8c148.tar.bz2
rneovim-34d808b73cbcb0a43636d826282193ab1ca8c148.zip
feat(api): combined highlights in nvim_eval_statusline()
Problem: Combined highlighting was not applied to nvim_eval_statusline(), and 'statuscolumn' sign segment/numhl highlights. Solution: Add an additional `groups` element to the return value of `nvim_eval_statusline()->highlights`. This is an array of stacked highlight groups (highest priority last). Also resolve combined highlights for the 'statuscolumn' sign segment/numhl highlights. Expose/synchronize some drawline.c logic that is now mimicked in three different places.
Diffstat (limited to 'runtime/lua/vim/_meta/api.lua')
-rw-r--r--runtime/lua/vim/_meta/api.lua4
1 files changed, 3 insertions, 1 deletions
diff --git a/runtime/lua/vim/_meta/api.lua b/runtime/lua/vim/_meta/api.lua
index 2f9ab5b846..6d9a17ea2b 100644
--- a/runtime/lua/vim/_meta/api.lua
+++ b/runtime/lua/vim/_meta/api.lua
@@ -1131,7 +1131,9 @@ function vim.api.nvim_eval(expr) end
--- the "highlights" key in {opts} is true. Each element of the array is a
--- |Dict| with these keys:
--- - start: (number) Byte index (0-based) of first character that uses the highlight.
---- - group: (string) Name of highlight group.
+--- - group: (string) Name of highlight group. May be removed in the future, use
+--- `groups` instead.
+--- - groups: (array) Names of stacked highlight groups (highest priority last).
function vim.api.nvim_eval_statusline(str, opts) end
--- @deprecated