Use new border option

This commit is contained in:
Dreaded_X 2025-05-26 19:04:30 +02:00
parent 0a88d94e42
commit f08c4fddcd
Signed by: Dreaded_X
GPG Key ID: 5A0CBFE3C3377FAA
4 changed files with 22 additions and 17 deletions

View File

@ -90,12 +90,7 @@ vim.api.nvim_create_autocmd("LspAttach", {
)
-- Documentation
vim.keymap.set("n", "K", function()
vim.lsp.buf.hover({ border = window.border })
end, { desc = "Hover Documentation" })
-- vim.keymap.set("n", "<C-k>", function()
-- vim.lsp.buf.signature_help({ border = border })
-- end, { desc = "Signature Documentation" })
-- vim.keymap.set("n", "<C-k>", vim.lsp.buf.signature_help, { desc = "Signature Documentation" })
end,
})
@ -128,7 +123,7 @@ vim.api.nvim_create_autocmd("LspAttach", {
end,
})
-- Setup cursor hover symbol highlight
-- Disable lsp based syntax highlighting
vim.api.nvim_create_autocmd("LspAttach", {
callback = function(event)
local client = vim.lsp.get_client_by_id(event.data.client_id)

View File

@ -1,5 +1,5 @@
local diagnostic = require("symbols.diagnostic")
local border = require("symbols.window").border
local window = require("symbols.window")
-- Set highlight on search
vim.o.hlsearch = true
@ -68,6 +68,9 @@ vim.o.list = true
-- Fold settings
vim.o.foldlevelstart = 99
-- Windows borders
vim.o.winborder = window.border
-- LSP config
vim.diagnostic.config({
severity_sort = true,

View File

@ -1,4 +1,3 @@
local window = require("symbols.window")
return {
"saghen/blink.cmp",
-- optional: provides snippets for the snippet source
@ -56,9 +55,6 @@ return {
documentation = {
auto_show = true,
auto_show_delay_ms = 0,
window = {
border = window.border,
},
},
menu = {
auto_show = true,
@ -77,15 +73,11 @@ return {
},
},
},
border = window.border,
},
},
signature = {
enabled = true,
window = {
border = window.border,
},
trigger = {
show_on_accept = true,
show_on_insert = true,

View File

@ -1,4 +1,5 @@
-- https://github.com/nvim-telescope/telescope.nvim
local window = require("symbols.window")
-- TODO: Ensure installed ripgrep
return {
"nvim-telescope/telescope.nvim",
@ -35,7 +36,7 @@ return {
["<S-Tab>"] = "move_selection_better",
},
},
borderchars = require("symbols.window").borderchars,
borderchars = window.borderchars,
},
extensions = {
["ui-select"] = {
@ -44,6 +45,20 @@ return {
},
})
-- HACK: Workaround until new borders are fixed in telescope
vim.api.nvim_create_autocmd("User", {
pattern = "TelescopeFindPre",
callback = function()
vim.opt_local.winborder = "none"
vim.api.nvim_create_autocmd("WinLeave", {
once = true,
callback = function()
vim.opt_local.winborder = window.border
end,
})
end,
})
require("telescope").load_extension("fzf")
require("telescope").load_extension("ui-select")