Neovim colorscheme based on the awesome Leaf KDE Plasma Theme by @qewer33.
There are low, medium and high contrast versions for both the dark and the light theme. The low contrast themes exactly match the colors from the corresponding KDE Plasma themes.
Download with your favorite package manager.
use "daschw/leaf.nvim"
- neovim >= 0.6
- truecolor terminal support
- undercurl terminal support (optional)
As simple as writing (pasting)
colorscheme leaf
vim.cmd("colorscheme leaf")
- Nvim cmp
- TreeSitter
- LSP Diagnostics
- Git Signs
- Telescope
- NvimTree
- Indent Blankline
- Dashboard
- Lualine
- FloaTerm
- Barbar
- Neogit
- SmoothCursor
And many others should "just work"!
There is no need to call setup if you are ok with the defaults (low contrast).
require("leaf").setup({
underlineStyle = "underline",
commentStyle = "italic",
functionStyle = "NONE",
keywordStyle = "italic",
statementStyle = "bold",
typeStyle = "NONE",
variablebuiltinStyle = "italic",
transparent = false,
colors = {},
overrides = {},
theme = "auto", -- default, based on vim.o.background, alternatives: "light", "dark"
contrast = "low", -- default, alternatives: "medium", "high"
})
-- setup must be called before loading
vim.cmd("colorscheme leaf")
You can change individual colors of leaf.nvim themes by passing a table of colors
to setup
.
Supported keywords can be found here and the theme's colors are defined here.
For example, for comments matching the theme's dark green color you can call setup with:
require("leaf").setup({
colors = { bg3 = "#59795f" },
})
You can achieve the same result by accessing the colors defined for leaf.nvim:
local leaf_colors = require("leaf.colors").setup()
require("leaf").setup({
colors = { bg3 = leaf_colors.leaf_green_3 },
})
With the overrides
keyword you can customize hl-groups.
Supported keywords are fg
, bg
, style
, guisp
and link
.
require("leaf").setup({
overrides = {
Normal = { fg = "black", bg = "#FFFFFF" },
Comment = { style = "italic" },
TelescopeBorder = { link = "Normal" },
},
})
- Almost all colors are taken from the Leaf KDE Plasma Theme by @qewer33. I just ported the konsole colors to Neovim and kitty.
- I used kanagawa.nvim by @rebelot as a template, since this is the first theme I made for Neovim.