liuchengxu / vista.vim

:cactus: Viewer & Finder for LSP symbols and tags

Home Page:https://liuchengxu.github.io/vista.vim

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

font with coc is not working

laoshaw opened this issue · comments

Describe the bug

after :Vista coc, the list shows strange icons

Environment:

  • OS: ubuntu 20.04

  • Vim/Neovim version: VIM - Vi IMproved 8.2 (2019 Dec 12, compiled Sep 28 2021 11:18:09)

  • This plugin version: a0469c6

  • I'm using universal-ctags: using coc, have ctags installed though, not sure if it's used by default

  • I'm using some LSP client:

    • Related Vim LSP client:coc and ale, but use newest coc for LSP
    • The Vim LSP client version:

Vista info

- Have you tried updated to the latest version of this LSP client: Yes/No
    Current FileType: cpp
Avaliable Executives: ['coc', 'ctags']
    Global Variables:
    let g:vista = {'get_tagline_under_cursor': function('378'), 'winnr': function('376'), 'source': {'fname': 'btop.cpp', 'bufnr': 1, 'get_winid': function('380'), 'winid':
1000, 'winnr': 1, 'extension': function('385'), 'line': function('383'), 'get_winnr': function('379'), 'filetype': function('381'), 'lines': function('382'), 'line_trimmed':
 function('384'), 'scope_seperator': function('386'), 'fpath': '/home/laoshaw/tmp/c.cpp/study-code-read/btop/src/btop.cpp'}, 'winid': function('377'), 'tmps': []}
    let g:vista#executives = ['ale', 'coc', 'ctags', 'lcn', 'nvim_lsp', 'vim_lsc', 'vim_lsp']
    let g:vista#extensions = ['markdown', 'rst']
    let g:vista#finders = ['clap', 'fzf', 'skim']
    let g:vista#renderer#icons = {'function': '', 'variable': ''}
    let g:vista_blink = [2, 100]
    let g:vista_close_on_fzf_select = 0
    let g:vista_close_on_jump = 0
    let g:vista_cursor_delay = 400
    let g:vista_default_executive = 'coc'
    let g:vista_disable_statusline = 0
    let g:vista_echo_cursor = 1
    let g:vista_enable_centering_jump = 1
    let g:vista_executive_for = {}
    let g:vista_find_absolute_nearest_method_or_function = 0
    let g:vista_find_nearest_method_or_function_delay = 300
    let g:vista_fold_toggle_icons = ['▼', '▶']
    let g:vista_fzf_preview = []
    let g:vista_icon_indent = ['└ ', '│ ']
    let g:vista_ignore_kinds = []
    let g:vista_no_mappings = 0
    let g:vista_sidebar_position = 'vertical botright'
    let g:vista_sidebar_width = 30
    let g:vista_stay_on_open = 1
    let g:vista_top_level_blink = [2, 100]
    let g:vista_update_on_text_changed = 0
    let g:vista_update_on_text_changed_delay = 500
let g:vista#renderer#icons = {'subroutine': '羚', 'method': '', 'func': '', 'variables': '', 'constructor': '略', 'field': '', 'interface': '', 'type': '', 'packag
es': '', 'property': '襁', 'implementation': '', 'default': '', 'augroup': 'פּ', 'macro': '', 'enumerator': '', 'const': '', 'macros': '', 'map': 'פּ', 'fields': '', '
functions': '', 'enum': '', 'function': '', 'target': '', 'typedef': '', 'namespace': '', 'enummember': '', 'variable': '', 'modules': '', 'constant': '', 'struct'
: '', 'types': '', 'module': '', 'typeParameter': '', 'package': '', 'class': '', 'member': '', 'var': '', 'union': '鬒'}

It looks like the g:vista#renderer#icons is incorrect, I'm using gnome-terminal.

Facing a similar issue.

My terminal emulator is Kitty and the font is monofur, which is a powerline-ready font (I also have PowerlineSymbols installed). This was all rendering just fine with the default icon and indent_icon settings until I updated last week.

I don't think it's related to vista.vim as there are almost no updates in the last a few months. If you don't see the other way around, just override g:vista#renderer#icons in your vimrc to replace the strange icons on your side.

Yes I ended up override all of them with ascii

Would it at least be possible to recommend some unicode fonts that provide reasonable glyphs? Of the 25 unique codepoints in renderer.vim, 9 of them are not covered by any font on my system and 10 of them are covered by only one font that has assigned calligraphic Tibetan glyphs to those codepoints. They're beautiful, but not helpful 😃 .