fixes and neovide suport

This commit is contained in:
Ward Truyen
2025-07-04 22:52:36 +02:00
parent 1aa0e3034d
commit ce889c3d17
4 changed files with 30 additions and 1 deletions

View File

@@ -7,3 +7,18 @@ require("ward.remap")
--$ instal/load Lazy plugin manager
require("ward.lazy")
--$ Neovide configuration if used
if vim.g.neovide then
vim.g.neovide_opacity = 0.7
vim.g.neovide_window_blurred = true
vim.o.guifont = "Source Code Pro:h14"
end
-- Sets colors to line numbers Above, Current and Below in this order
function LineNumberColors()
vim.api.nvim_set_hl(0, 'LineNrAbove', { fg='#51B3EC', bold=true })
vim.api.nvim_set_hl(0, 'LineNr', { fg='white', bold=true })
vim.api.nvim_set_hl(0, 'LineNrBelow', { fg='#FB508F', bold=true })
end
LineNumberColors()

View File

@@ -3,7 +3,7 @@
--$ help: nvim-cmp
return {
"hrsh7th/nvim-cmp",
event = "InsertEnter",
-- event = "InsertEnter",
dependencies = {
-- Snippet Engine & its associated nvim-cmp source
{

View File

@@ -28,10 +28,21 @@ return {
}
lspconfig.clangd.setup({
keys = {
{ "<leader>pc", "<cmd>ClangdSwitchSourceHeader<cr>", desc = "Switch Source/Header (C/C++)" },
},
cmd = {
"clangd",
"--offset-encoding=utf-16",
"--background-index",
"--clang-tidy",
"--header-insertion=iwyu",
"--completion-style=detailed",
"--function-arg-placeholders",
"-j4",
"--fallback-style=llvm",
},
filetypes = { "c", "cpp", "objc", "objcpp", "cuda", "proto", "hpp" },
init_options = {
fllbackFlags = { '-std=c++20' },
},

View File

@@ -16,6 +16,9 @@ return {
view = {
width = 32,
},
filters = {
git_ignored = false,
},
})
vim.keymap.set("n", "<leader>e", vim.cmd.NvimTreeToggle)
vim.api.nvim_create_autocmd({"QuitPre"}, { callback = function() vim.cmd("NvimTreeClose") end, })