Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

closing floating window with a split window closes current window #2470

Closed
marene opened this issue Oct 16, 2020 · 3 comments
Closed

closing floating window with a split window closes current window #2470

marene opened this issue Oct 16, 2020 · 3 comments

Comments

@marene
Copy link

marene commented Oct 16, 2020

Result from CocInfo

## versions

vim version: NVIM v0.4.4
node version: v12.19.0
coc.nvim version: 0.0.79-80ae19dee6
coc.nvim directory: /Users/matthieu.arene/.local/share/nvim/plugged/coc.nvim
term: iTerm.app
platform: darwin

Describe the bug

When a split window (or a tab) is open, and a coc floating window pops up (for example when the cursor gets placed on a warning, or when the documentation of a symbol gets consulted), if the cursor is moved, then the current window is closed.
(see screenshot section for more clarity).

This baffles me because I had close to exactly the same nvim/coc setup on my previous work macbook three days ago, and it worked just fine: I possibly done a stupid configuration mistake, but I just cannot find it.

Reproduce the bug

  • Create file mini.vim with:

    set nocompatible
    set runtimepath^=/Users/matthieu.arene/.local/share/nvim/plugged/coc.nvim
    filetype plugin indent on
    syntax on
    set hidden
    call plug#begin(stdpath('data') . '/plugged')
    Plug 'neoclide/coc.nvim', {'branch': 'release'}
    call plug#end()
  • Start (neo)vim with command: vim -u mini.vim

  • Open a split window, in one of those windows navigate to a warning (or hover over a documented symbol). Once a floating window pops up, move the cursor and the current window will close

Screenshots

output

@chemzqm
Copy link
Member

chemzqm commented Oct 16, 2020

Fixed on latest release branch of coc.nvim.

@chemzqm chemzqm closed this as completed Oct 16, 2020
@marene marene changed the title closing closing floating window with a split window closes current window Oct 17, 2020
@marene
Copy link
Author

marene commented Oct 17, 2020

Ah, I feel silly now, thanks a bunch!
Out of curiosity, what precise commit did fix this? I'm asking because I installed coc on the 15th (with Plug 'neoclide/coc.nvim', {'branch': 'release'}'), so I guess it was a recent one?

@chemzqm
Copy link
Member

chemzqm commented Oct 17, 2020

d4d93dc - fix(util): check winid for coc#util#close_win

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants