this post was submitted on 16 Jul 2023
13 points (100.0% liked)

Neovim

29 readers
1 users here now

founded 1 year ago
MODERATORS
 

I like mixing the keyboard and mouse. Yes I know

set mouse=a

exists, but it provides only some basic actions. I was wondering if you could map the mouse to allow moving split window panes around - something which is painful to do by keyboard. Do you know of something like this?

#vim #neovim

@vim @neovim

you are viewing a single comment's thread
view the rest of the comments
[–] tshirtman@mas.to 4 points 1 year ago* (last edited 1 year ago) (1 children)

@scy @ashwinvis @vim @neovim in my experience this works for *resizing* but not moving windows/panels around.

My solution to that is keyboard driven, but it's a plugin i wrote which allows swapping the currently focused window with a different one, by typing its letter.

I only tested it on vim, not neovim, but if it's possible to make it neovim compatible, i do welcome patches.

https://asciinema.org/a/0laV3PGpmCXkkazet0hIRf51W

https://github.com/tshirtman/vim-winny

[–] ashwinvis@mastodon.acc.sunet.se 4 points 1 year ago (2 children)

@tshirtman
Ooh... like a tiling window manager. I will check it out. I like the labelled popups in front of panes.

I see something similar written in Lua.

https://github.com/sindrets/winshift.nvim

@scy @vim @neovim

[–] tshirtman@mas.to 1 points 1 year ago* (last edited 1 year ago)

@ashwinvis @scy @vim @neovim oh the one you found seem more powerful than mine, behaving a lot more like i3wm, nice, sadly only neovim compatible, but it's nice to know it exists, panes management is really a pain point in vim when you open more than a couple of them.

load more comments (1 replies)