xiyaowong / transparent.nvim

Remove all background colors to make nvim transparent
806 stars 23 forks source link

Bufferline elements not transparent #49

Closed TakenMC closed 1 year ago

TakenMC commented 1 year ago

I have this weird issue when I enter nvim it would make almost everything transparent besides a few bufferline icons. Tho it would be all normal when I would disable it and enable it

Here's what it looks like image

xiyaowong commented 1 year ago

Have you tried this?

vim.g.transparent_groups = vim.list_extend(
  vim.g.transparent_groups or {},
  vim.tbl_map(function(v)
    return v.hl_group
  end, vim.tbl_values(require('bufferline.config').highlights))
)
TakenMC commented 1 year ago

Ill try it out later when i am home

TakenMC commented 1 year ago

I still have the file icon with weird background image

xiyaowong commented 1 year ago

@TakenMC Which plugin for icons you're using?

TakenMC commented 1 year ago

nvim web dev icons the one everyone recommends

xiyaowong commented 1 year ago

Does hi DevIconLua have bg color? Actually I can't reproduce the issue.

TakenMC commented 1 year ago

should i add that to the extra groups

xiyaowong commented 1 year ago

What theme you're using?

TakenMC commented 1 year ago

onedarkpro vivid by olimorris

xiyaowong commented 1 year ago

@TakenMC Tried this theme, doesn't have this issue. image

Can you show me your bufferline configuration?BufferLine will define BufferLineDevIcon{lang}{state} when you open a file, so you should ensure the parent highlights have been cleared. image https://github.com/akinsho/bufferline.nvim/blob/417b303328118b6d836ae330142e88771c48a8a3/lua/bufferline/highlights.lua#L99C1-L103C12

TakenMC commented 1 year ago

I'll get it when im home later

TakenMC commented 1 year ago

nvm i am stupid and forgot i have the config on gitlab https://gitlab.com/taken-personal/neovim-config/-/blob/main/after/plugin/bufferline.lua

xiyaowong commented 1 year ago

You should add this snippet to the bottom

vim.g.transparent_groups = vim.list_extend(
  vim.g.transparent_groups or {},
  vim.tbl_map(function(v)
    return v.hl_group
  end, vim.tbl_values(require('bufferline.config').highlights))
)
TakenMC commented 1 year ago

the ft icon is still not transparent

TakenMC commented 1 year ago

nvm it works now perfectly