sam4llis / nvim-tundra

A theme for Neovim with support for LSP, Treesitter, Telescope, and more.
264 stars 6 forks source link

Set `termguicolors` within Tundra #5

Closed mattjamesdev closed 2 years ago

mattjamesdev commented 2 years ago

I noticed other colourscheme plugins set termguicolors within their plugin, whereas this one doesn't. This causes the colourscheme to not be applied properly if termguicolors is not set explicitly by the user elsewhere in their config.

Setting the colourscheme on its own (everything is blank):

Screen Shot 2022-09-10 at 4 07 46 pm

After entering :set termguicolors:

Screen Shot 2022-09-10 at 4 07 58 pm

Based on what I've seen in other colourschemes' "init.lua"s, I think it should be as simple as adding the line vim.opt.termguicolors = true somewhere in the M.load function of lua/nvim-tundra/init.lua.

sam4llis commented 2 years ago

Nice, this should be relatively easy to implement (and I’ll probably sort it out this weekend). Thanks for bringing this to my attention :)

sam4llis commented 2 years ago

Commit 2182bed in the dev branch adds the suggested vim.opt.termguicolors = true to the colorscheme. I decided to add it externally from the M.load function in colors/tundra.lua as I want M.load to be specifically for applying or reloading highlight groups. I'll leave it a couple of days before merging to main and closing the issue to check it works as intended :)

mattjamesdev commented 2 years ago

Awesome, thanks for looking into it!

sam4llis commented 2 years ago

Cherry picked commit (from 2182bed) e08d397 into main branch. Users don't need to set termguicolors to true in their Neovim configuration any longer :)