aboutsummaryrefslogtreecommitdiff
path: root/lua
diff options
context:
space:
mode:
authorjdhao <jdhao@hotmail.com>2022-02-11 20:15:07 +0800
committerjdhao <jdhao@hotmail.com>2022-02-11 20:15:07 +0800
commit528aa2f19ad4aa6f6b53080d4f523ee1b3e15b86 (patch)
treeb6da648f406fc9f75d7c2a57e090e5ffa61b699d /lua
parent295f47b1fb1b8a56832400f672b8c7b9746684d0 (diff)
update nvim-cmp conf
Diffstat (limited to 'lua')
-rw-r--r--lua/config/nvim-cmp.lua25
1 files changed, 22 insertions, 3 deletions
diff --git a/lua/config/nvim-cmp.lua b/lua/config/nvim-cmp.lua
index 8146d61..e9f5781 100644
--- a/lua/config/nvim-cmp.lua
+++ b/lua/config/nvim-cmp.lua
@@ -41,8 +41,8 @@ cmp.setup({
keyword_length = 1,
completeopt = "menu,noselect"
},
- experimental = {
- ghost_text = false
+ view = {
+ entries = 'custom',
},
formatting = {
format = lspkind.cmp_format({
@@ -59,4 +59,23 @@ cmp.setup({
},
})
-vim.cmd("hi link CmpItemMenu Comment")
+-- see https://github.com/hrsh7th/nvim-cmp/wiki/Menu-Appearance#how-to-add-visual-studio-code-dark-theme-colors-to-the-menu
+vim.cmd[[
+ highlight! link CmpItemMenu Comment
+ " gray
+ highlight! CmpItemAbbrDeprecated guibg=NONE gui=strikethrough guifg=#808080
+ " blue
+ highlight! CmpItemAbbrMatch guibg=NONE guifg=#569CD6
+ highlight! CmpItemAbbrMatchFuzzy guibg=NONE guifg=#569CD6
+ " light blue
+ highlight! CmpItemKindVariable guibg=NONE guifg=#9CDCFE
+ highlight! CmpItemKindInterface guibg=NONE guifg=#9CDCFE
+ highlight! CmpItemKindText guibg=NONE guifg=#9CDCFE
+ " pink
+ highlight! CmpItemKindFunction guibg=NONE guifg=#C586C0
+ highlight! CmpItemKindMethod guibg=NONE guifg=#C586C0
+ " front
+ highlight! CmpItemKindKeyword guibg=NONE guifg=#D4D4D4
+ highlight! CmpItemKindProperty guibg=NONE guifg=#D4D4D4
+ highlight! CmpItemKindUnit guibg=NONE guifg=#D4D4D4
+]]