From f826490a51e2c2f5eda1b3c5c4a093d2f429d400 Mon Sep 17 00:00:00 2001 From: ksyasuda Date: Fri, 11 Feb 2022 11:57:44 -0800 Subject: [PATCH] fix border chars --- nvim/keybindings.vim | 8 ++--- nvim/plugin-confs/goto-preview.lua | 3 +- nvim/plugin-confs/lspconfig.lua | 55 +++++++++++++++++++----------- 3 files changed, 41 insertions(+), 25 deletions(-) diff --git a/nvim/keybindings.vim b/nvim/keybindings.vim index 58fbbb8..896b846 100644 --- a/nvim/keybindings.vim +++ b/nvim/keybindings.vim @@ -35,10 +35,6 @@ nmap Q !!$SHELL nmap rn :lua vim.lsp.buf.rename() -nmap wa :lua vim.lsp.buf.add_workspace_folder() -nmap wl :lua print(vim.inspect(vim.lsp.buf.list_workspace_folders())) -nmap wr :lua vim.lsp.buf.remove_workspace_folder() - nmap as :FloatermNew --title=aniwrapper aniwrapper -qtdoomone -D144 nmap ad :FloatermNew --title=aniwrapper ani-cli -q720p -cd/home/sudacode/Videos/sauce -D144 @@ -99,6 +95,10 @@ nnoremap tc :DashboardChangeColorscheme nmap to :SymbolsOutline nmap tt :FloatermToggle vsplit-term +nmap wa :lua vim.lsp.buf.add_workspace_folder() +nmap wl :lua print(vim.inspect(vim.lsp.buf.list_workspace_folders())) +nmap wr :lua vim.lsp.buf.remove_workspace_folder() + nnoremap xd TroubleToggle document_diagnostics nnoremap xl TroubleToggle loclist nnoremap xq TroubleToggle quickfix diff --git a/nvim/plugin-confs/goto-preview.lua b/nvim/plugin-confs/goto-preview.lua index ef8aa7d..8309252 100644 --- a/nvim/plugin-confs/goto-preview.lua +++ b/nvim/plugin-confs/goto-preview.lua @@ -1,7 +1,8 @@ require('goto-preview').setup { width = 120; -- Width of the floating window height = 20; -- Height of the floating window - border = {"↖", "─" ,"┐", "│", "┘", "─", "└", "│"}; -- Border characters of the floating window + border = {"╭", "─" ,"╮", "│", "╯", "─", "╰", "│"}; -- Border characters of the floating window + -- border = {"┌", "─" ,"┐", "│", "┘", "─", "└", "│"}; -- Border characters of the floating window default_mappings = false; -- Bind default mappings debug = false; -- Print debug information opacity = 25; -- 0-100 opacity level of the floating window where 100 is fully transparent. diff --git a/nvim/plugin-confs/lspconfig.lua b/nvim/plugin-confs/lspconfig.lua index d4a8a28..f635d00 100644 --- a/nvim/plugin-confs/lspconfig.lua +++ b/nvim/plugin-confs/lspconfig.lua @@ -44,15 +44,30 @@ end vim.cmd [[autocmd! ColorScheme * highlight NormalFloat guibg=#1f2335]] vim.cmd [[autocmd! ColorScheme * highlight FloatBorder guifg=white guibg=#1f2335]] +-- squared corners + +-- local border = { +-- {"┌", "FloatBorder"}, +-- {"─", "FloatBorder"}, +-- {"┐", "FloatBorder"}, +-- {"|", "FloatBorder"}, +-- {"┘", "FloatBorder"}, +-- {"─", "FloatBorder"}, +-- {"└", "FloatBorder"}, +-- {"|", "FloatBorder"}, +-- } + +-- rounded + local border = { - {"🭽", "FloatBorder"}, - {"▔", "FloatBorder"}, - {"🭾", "FloatBorder"}, - {"▕", "FloatBorder"}, - {"🭿", "FloatBorder"}, - {"▁", "FloatBorder"}, - {"🭼", "FloatBorder"}, - {"▏", "FloatBorder"}, + {"╭", "FloatBorder"}, + {"─", "FloatBorder"}, + {"╮", "FloatBorder"}, + {"│", "FloatBorder"}, + {"╯", "FloatBorder"}, + {"─", "FloatBorder"}, + {"╰", "FloatBorder"}, + {"│", "FloatBorder"}, } local handlers = { @@ -85,7 +100,7 @@ local DEFAULT_SETTINGS = { }, -- The directory in which to install all servers. - install_root_dir = "~/.vim/lsp", + -- install_root_dir = "/home/sudacode/.vim/lsp", pip = { -- These args will be added to `pip install` calls. Note that setting extra args might impact intended behavior @@ -95,7 +110,7 @@ local DEFAULT_SETTINGS = { install_args = {}, }, on_attach = on_attach, - -- handlers=handlers, + handlers=handlers, -- Controls to which degree logs are written to the log file. It's useful to set this to vim.log.levels.DEBUG when -- debugging issues with server installations. @@ -161,13 +176,13 @@ end) -- Use a loop to conveniently call 'setup' on multiple servers and -- map buffer local keybindings when the language server attaches --- local servers = { 'pyright', 'bashls', 'sqlls' } --- for _, lsp in pairs(servers) do --- require('lspconfig')[lsp].setup { --- on_attach = on_attach, --- flags = { --- -- This will be the default in neovim 0.7+ --- debounce_text_changes = 150, --- } --- } --- end +local servers = { 'pyright', 'bashls', 'sqls', 'vimls', 'yamlls', 'dockerls', 'html', 'sumneko_lua', 'jsonls', 'dotls' } +for _, lsp in pairs(servers) do + require('lspconfig')[lsp].setup { + on_attach = on_attach, + flags = { + -- This will be the default in neovim 0.7+ + debounce_text_changes = 150, + } + } +end