mirror of
https://github.com/stevearc/aerial.nvim
synced 2024-09-16 14:34:08 +02:00
feat: add new AerialNormal
highlight as a fallback for all text (#278)
* feat: add new `AerialNormal` highlight as a fallback for all text * [docgen] Update docs skip-checks: true --------- Co-authored-by: Github Actions <actions@github>
This commit is contained in:
parent
66078ea0fa
commit
b4eb257e54
2 changed files with 16 additions and 1 deletions
|
@ -661,6 +661,9 @@ hi link AerialClassIcon Special
|
|||
hi link AerialFunction Special
|
||||
hi AerialFunctionIcon guifg=#cb4b16 guibg=NONE guisp=NONE gui=NONE cterm=NONE
|
||||
|
||||
" There's also this group for the fallback of the text if a specific
|
||||
" class highlight isn't defined
|
||||
hi link AerialNormal Normal
|
||||
" There's also this group for the cursor position
|
||||
hi link AerialLine QuickFixLine
|
||||
" If highlight_mode="split_width", you can set a separate color for the
|
||||
|
|
|
@ -55,6 +55,18 @@ M.get_highlight = function(symbol, is_icon, is_collapsed)
|
|||
end
|
||||
|
||||
M.create_highlight_groups = function()
|
||||
-- Use Normal colors for AerialNormal, while stripping bold/italic/etc
|
||||
local normal_defn = vim.api.nvim_get_hl_by_name("Normal", true)
|
||||
-- The default text highlight
|
||||
vim.api.nvim_set_hl(0, "AerialNormal", {
|
||||
fg = normal_defn.foreground,
|
||||
bg = normal_defn.background,
|
||||
ctermfg = normal_defn.ctermfg,
|
||||
ctermbg = normal_defn.ctermbg,
|
||||
blend = normal_defn.blend,
|
||||
default = true,
|
||||
})
|
||||
|
||||
-- The line that shows where your cursor(s) are
|
||||
link("AerialLine", "QuickFixLine")
|
||||
link("AerialLineNC", "AerialLine")
|
||||
|
@ -80,7 +92,7 @@ M.create_highlight_groups = function()
|
|||
|
||||
-- The name of the symbol
|
||||
for _, symbol_kind in ipairs(symbol_kinds) do
|
||||
link(string.format("Aerial%s", symbol_kind), "NONE")
|
||||
link(string.format("Aerial%s", symbol_kind), "AerialNormal")
|
||||
end
|
||||
|
||||
-- The icon displayed to the left of the symbol
|
||||
|
|
Loading…
Reference in a new issue