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

Replace the input() calls in sandwiches that take input with neovim floating windows? #120

Open
IndianBoy42 opened this issue Oct 11, 2021 · 0 comments

Comments

@IndianBoy42
Copy link

IMO using small floating windows anchored to the cursor is a better input method as we do not need to move our eyes to the bottom of the screen. I would like to change the builtin bun functions with one that uses such a floating window based interface. It is easy to program such an interface, but I am not sure how to use the same interface as input(). I do something similar here in my vim config for making a better interface for vim.lsp.buf.rename(). In this when i hit <CR> in the floating window it calls vim.lsp.buf.rename(<input>). So basically it works well when I can just call a function at the end of the input process to do the action. input() however is essentially a blocking call to vim to get some input, I don't know if some of the neovim async stuff could be used here to turn my callback based interface into a blocking style interface.
Is there anyone knowledgable in neovim who could help implement some floating window based input method for vim-sandwich or could guide me to making it?

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