feat: highlight group for counter: TelescopePromptCounter

fix #1540
This commit is contained in:
Simon Hauser
2021-12-03 14:36:32 +01:00
parent 4b3efd2341
commit 4e075bf924
2 changed files with 3 additions and 1 deletions

View File

@@ -1095,7 +1095,7 @@ function Picker:get_status_updater(prompt_win, prompt_bufnr)
local text = self:get_status_text(opts) local text = self:get_status_text(opts)
vim.api.nvim_buf_clear_namespace(prompt_bufnr, ns_telescope_prompt, 0, -1) vim.api.nvim_buf_clear_namespace(prompt_bufnr, ns_telescope_prompt, 0, -1)
vim.api.nvim_buf_set_extmark(prompt_bufnr, ns_telescope_prompt, 0, 0, { vim.api.nvim_buf_set_extmark(prompt_bufnr, ns_telescope_prompt, 0, 0, {
virt_text = { { text, "NonText" } }, virt_text = { { text, "TelescopePromptCounter" } },
virt_text_pos = "right_align", virt_text_pos = "right_align",
}) })

View File

@@ -35,6 +35,8 @@ highlight default link TelescopePromptTitle TelescopeTitle
highlight default link TelescopeResultsTitle TelescopeTitle highlight default link TelescopeResultsTitle TelescopeTitle
highlight default link TelescopePreviewTitle TelescopeTitle highlight default link TelescopePreviewTitle TelescopeTitle
highlight default link TelescopePromptCounter NonText
" Used for highlighting characters that you match. " Used for highlighting characters that you match.
highlight default link TelescopeMatching Special highlight default link TelescopeMatching Special