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

Splits with WinBar change size when opening and closing FZF #1501

Open
5 tasks done
maybeetree opened this issue Sep 5, 2023 · 0 comments
Open
5 tasks done

Splits with WinBar change size when opening and closing FZF #1501

maybeetree opened this issue Sep 5, 2023 · 0 comments

Comments

@maybeetree
Copy link

maybeetree commented Sep 5, 2023

Splits with WinBar change size when opening and closing FZF

Description

If a split has a WinBar, opening and closing FZF in the split above it causes it to shrink.
Video demonstration of this bug: https://asciinema.org/a/nYiOnge1cr5FXbbAcc4pLZGF6

How to reproduce

  1. Launch vim with vim --clean -Nu <(curl https://gist.githubusercontent.com/junegunn/6936bf79fedd3a079aeb1dd2f3c81ef5/raw)
  2. Wait for vim-plug to install everything
  3. Close the split created by vim-plug so that the window contains one empty split
  4. Split the window horizontally, such that there are two splits, one above the other
  5. Switch to the BOTTOM split
  6. In the BOTTOM split, run the following vim command in order to create a WinBar: :nnoremenu 1.10 WinBar.Step :Step<CR>
  7. Switch to the TOP split
  8. In the TOP split, run the following vim command: :FZF
  9. Press ESC to close the FZF popup

Expected behavior

The sizes of the two splits stay the same

Actual behavior

The bottom split shrinks by one line. Repeating the last two steps keeps on shrinking the split, until it becomes unusably small.

Why would anyone care?

Vimspector is another popular plugin that uses WinBar heavily. This issue is a major inconvenience for people who want to use Vimspector and fzf.vim together. They are left with three chpices: disabling WinBar support in Vimspector (let g:vimspector_enable_winbar=0); constantly re-adjusting the size of their splits; or trying to avoid using fzf when debugging. None of these are satisfactory.

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

1 participant