Koalhack / koalight.nvim

A Moonlight colorscheme port for neovim
MIT License
10 stars 0 forks source link

How do you set the transparent brackgound? #2

Closed sebalfaro closed 5 months ago

sebalfaro commented 5 months ago

Hi there, i wanted to set the background and use the transparent one that you have in this image, how do you do that? Thanks!!

image

Koalhack commented 5 months ago

Hello, I'll be glad to help you.

  1. First of all, you need to use a terminal emulator that supports transparent background (Windows Terminal, iTerm, Warp, etc...) and configure it to be transparent/translucent.
  2. Secondly, my koalight.nvim theme doesn't support transparency at the moment, so you'll need to use the transparent.nvim plugin or you can try this snippet vim.api.nvim_set_hl(0, 'Normal', { bg = 'none' }).

I hope this helps, if you have any further problems please don't hesitate to open a question. Best regards

Koalhack commented 5 months ago

Here is my configuration file for the transparent.nvim plugin

local M = {
  'xiyaowong/nvim-transparent'
}

function M.config()
  local status, transparent = pcall(require, 'transparent')
  if (not status) then return end

  transparent.setup({
    extra_groups = { -- table/string: additional groups that should be cleared

      --telescope.nvim
      "FloatBorder",
      "TelescopeNormal",

      --Cmp.nvim
      "Pmenu",
      "Float",
      "NormalFloat",

      -- nvim-bufferline.lua
      "BufferLineFill",
      "BufferLineBackground",
    },
    exclude_groups = {}, -- table: groups you don't want to clear
  })
end

return M
sebalfaro commented 5 months ago

Here is my configuration file for the transparent.nvim plugin

local M = {
  'xiyaowong/nvim-transparent'
}

function M.config()
  local status, transparent = pcall(require, 'transparent')
  if (not status) then return end

  transparent.setup({
    extra_groups = { -- table/string: additional groups that should be cleared

      --telescope.nvim
      "FloatBorder",
      "TelescopeNormal",

      --Cmp.nvim
      "Pmenu",
      "Float",
      "NormalFloat",

      -- nvim-bufferline.lua
      "BufferLineFill",
      "BufferLineBackground",
    },
    exclude_groups = {}, -- table: groups you don't want to clear
  })
end

return M

Working on my end, thank you!!