As far as I can tell, creating a split with :split
or :vsplit
changes focus (the current window) to the newly opened one. Is it possible to avoid changing focus? I am working on a plugin that opens padding buffers with splits and changing focus is undesirable.
nvim_open_win
has an enter
option for whether the new window should be focused. There’s a caveat though: there’s a script running before VimEnter
that focuses the first window.