mirror of
https://github.com/neovim/neovim.git
synced 2025-10-21 09:12:07 +00:00
feat(api): nvim_open_win() relative to tabline and laststatus #32006
Problem: Anchoring a floating window to the tabline and laststatus is cumbersome; requiring autocommands and looping over all windows/tabpages. Solution: Add new "tabline" and "laststatus" options to the `relative` field of nvim_open_win() to place a window relative to.
This commit is contained in:
10
runtime/lua/vim/_meta/api.lua
generated
10
runtime/lua/vim/_meta/api.lua
generated
@@ -1754,10 +1754,12 @@ function vim.api.nvim_open_term(buffer, opts) end
|
||||
--- @param config vim.api.keyset.win_config Map defining the window configuration. Keys:
|
||||
--- - relative: Sets the window layout to "floating", placed at (row,col)
|
||||
--- coordinates relative to:
|
||||
--- - "editor" The global editor grid
|
||||
--- - "win" Window given by the `win` field, or current window.
|
||||
--- - "cursor" Cursor position in current window.
|
||||
--- - "mouse" Mouse position
|
||||
--- - "cursor" Cursor position in current window.
|
||||
--- - "editor" The global editor grid.
|
||||
--- - "laststatus" 'laststatus' if present, or last row.
|
||||
--- - "mouse" Mouse position.
|
||||
--- - "tabline" Tabline if present, or first row.
|
||||
--- - "win" Window given by the `win` field, or current window.
|
||||
--- - win: `window-ID` window to split, or relative window when creating a
|
||||
--- float (relative="win").
|
||||
--- - anchor: Decides which corner of the float to place at (row,col):
|
||||
|
Reference in New Issue
Block a user