1
0
Fork 0

nvim: statuscolumn

This commit is contained in:
Vladimír Dudr 2023-02-11 14:25:34 +01:00
parent c6abd232bd
commit dea718004b
2 changed files with 36 additions and 13 deletions

View file

@ -42,7 +42,6 @@ function M.setup()
--vim.o.clipboard = "unnamedplus" --vim.o.clipboard = "unnamedplus"
vim.o.guifont = 'Hack:12h' vim.o.guifont = 'Hack:12h'
vim.o.list = true vim.o.list = true
vim.o.listchars = 'tab:❮⋯❯,trail:⸬,nbsp:·' vim.o.listchars = 'tab:❮⋯❯,trail:⸬,nbsp:·'
@ -75,7 +74,7 @@ function M.setup()
if vim.bo[buf].filetype ~= 'qf' then if vim.bo[buf].filetype ~= 'qf' then
vim.wo.statusline = '%Y %f%=%l:%v %P' vim.wo.statusline = '%Y %f%=%l:%v %P'
end end
end end,
}) })
vim.api.nvim_create_autocmd({ 'BufEnter', 'FileType' }, { vim.api.nvim_create_autocmd({ 'BufEnter', 'FileType' }, {
@ -90,10 +89,14 @@ function M.setup()
vim.b[args.buf].trouble_mode = table.concat(words, ' ') vim.b[args.buf].trouble_mode = table.concat(words, ' ')
vim.wo.statusline = '%Y [%{b:trouble_mode}]%=%P' vim.wo.statusline = '%Y [%{b:trouble_mode}]%=%P'
end end,
}) })
if vim.g.neoray then if vim.fn.has('nvim-0.9') then
vim.o.statuscolumn = '%C%3l %s'
end
if vim.g.neoray then -- {{{
vim.cmd.NeoraySet('CursorAnimTime', 0) vim.cmd.NeoraySet('CursorAnimTime', 0)
vim.cmd.NeoraySet('Transparency', '0.95') vim.cmd.NeoraySet('Transparency', '0.95')
vim.cmd.NeoraySet('TargetTPS', 120) vim.cmd.NeoraySet('TargetTPS', 120)
@ -103,9 +106,7 @@ function M.setup()
vim.cmd.NeoraySet('WindowState', 'none') vim.cmd.NeoraySet('WindowState', 'none')
vim.cmd.NeoraySet('KeyZoomIn', '<>') vim.cmd.NeoraySet('KeyZoomIn', '<>')
vim.cmd.NeoraySet('KeyZoomOut', '<>') vim.cmd.NeoraySet('KeyZoomOut', '<>')
end end -- }}}
end end
return M return M

View file

@ -0,0 +1,22 @@
local pal = require('configs.colors').pallete
local function make_override(icon, color, name)
local col = pal[color] or color
return {
icon = icon,
color = col[1] or col,
cterm_color = col[2] or col,
name = name,
}
end
return {
'nvim-tree/nvim-web-devicons',
opts = {
override = {
xml = make_override('󰗀', 'orange', 'XML'),
bash = make_override('', 'green', 'Bash'),
sh = make_override('󱆃', 'green', 'Sh'),
},
},
}