Closed hadronized closed 3 years ago
Issue-Label Bot is automatically applying the label bug
to this issue, with a confidence of 0.96. Please mark this comment with :thumbsup: or :thumbsdown: to give our bot feedback!
Links: app homepage, dashboard and code for this bot.
I don't think vim-clap is responsible for this issue as you even don't open it. And you are not opening two Vim windows, but two terminal windows. I guess the other fuzzy finders will have the same problem as it's probably an issue of neovim itself, try fzf.vim, see if this issue persists.
No problem with fzf.vim; as mentioned in the issue, the problem disappears as soon as I remove vim-clap
from my plugins.
I still don't see why vim-clap is related.
I tried to :profile
but I got a zero-byte profile file (maybe I miss something here). Do you have any idea how I could debug that issue?
Maybe this can help https://vi.stackexchange.com/a/277
Yeah, I get a trace but I’m not sure how it’s going to be interesting. I guess you are using a display feature and not resetting it / using it correctly, because I don’t have the bug with other plugins. However, it looks like it’s not triggered if I start neovim and do not use any clap feature (it starts doing it as soon as I do for instance :Clap buffers
). Even with the clap floating window closed, it still behaves incorrectly afterwards.
EDIT: it’s not a focus issue because even when getting the focus back, the window still doesn’t redraw. An input is required.
it looks like it’s not triggered if I start neovim and do not use any clap feature
That's why I don't understand clap is related here, if you don't open clap, there is only a few autocmds of clap taking effect, see https://github.com/liuchengxu/vim-clap/blob/master/plugin/clap.vim, which won't lead to this issue in my opinion.
Yes, agreed. So the problem happens after a clap window has been opened. I can open a clap window, close it, resize the window: the problem appears. A clap window doesn’t have to be open for the problem to appear, but it looks like one has to have been opened previously (at least once).
I just want to confirm that I have this exact same issue using neovim nightly and clap on ubuntu. I have tried using both ctrlp and fzf, without getting this issue, but as soon as I search using clap the rescaling on window resize stops working correctly and requires an additional key press before looking correct again. As op mentioned, this behavior starts when I open clap, and persists even after I close the clap window until I exit neovim.
Yes, I still have it too. I’m not sure what causes it, though. :(
The same here. Using tiling window manager. 1) Open a terminal and start nvim
in it. Open a file with :e /path/to/file
. Open another terminal, so that the first one shrinks. Then close the second terminal. The terminal with nvim
grows back. No probem. 2) Do the same steps, but instead of :e /path/to/file
use, e.g. :Clap history
to open file. Then on the last step (after nvim
's terminal is restored to original size), the content is jumbled up. Have to use Ctrl-L to redraw.
Does it still happen if you apply this patch?
diff --git a/autoload/clap/floating_win.vim b/autoload/clap/floating_win.vim
index e94ad1a..9cdf23a 100644
--- a/autoload/clap/floating_win.vim
+++ b/autoload/clap/floating_win.vim
@@ -84,6 +84,7 @@ function! g:clap#floating_win#display.open() abort
endfunction
function! clap#floating_win#redo_layout() abort
+ return
let s:display_opts = clap#layout#calc()
call nvim_win_set_config(s:display_winid, s:display_opts)
call nvim_win_set_config(s:spinner_winid, s:get_config_spinner())
No, it doesn't. The problem disappers after applying the patch.
Warning: if you don't fill this issue template and provide the reproducible steps the issue could be closed directly.
Environment (please complete the following information):
Features: +acl +iconv +tui
has py dynamic module: 1 Current FileType: toml Third Party Providers: [] Global Options: let g:clap#autoload_dir = '/home/phaazon/.config/nvim/plugged/vim-clap/autoload' let g:clap#provider_alias = {'gfiles': 'git_files', 'hist:': 'command_history', 'hist/': 'search_history'} let g:clap_current_selection_sign = {'texthl': 'ClapCurrentSelectionSign', 'linehl': 'ClapCurrentSelection', 'text': '->'} let g:clap_disable_bottom_top = 0 let g:clap_disable_matches_indicator = v:false let g:clap_disable_optional_async = v:false let g:clap_disable_run_rooter = v:false let g:clap_enable_debug = v:false let g:clap_enable_icon = 1 let g:clap_forerunner_status_sign = {'done': '•', 'running': '!', 'using_cache': '*'} let g:clap_fuzzy_match_hl_groups = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0] let g:clap_insert_mode_only = v:true let g:clap_multi_selection_warning_silent = 0 let g:clap_no_matches_msg = 'NO MATCHES FOUND' let g:clap_open_action = {'ctrl-v': 'vsplit', 'ctrl-x': 'split', 'ctrl-t': 'tab split'} let g:clap_popup_border = 'rounded' let g:clap_preview_size = 5 let g:clap_providers_relaunch_code = '@@' let g:clap_search_box_border_style = 'nil' let g:clap_search_box_border_symbols = {'nil': ['', ''], 'curve': ['', ''], 'arrow': ['', '']} let g:clap_selected_sign = {'texthl': 'ClapSelectedSign', 'linehl': 'ClapSelected', 'text': ' ·'} Provider Variables: []