mirror of
https://github.com/neovim/neovim.git
synced 2025-10-14 05:46:12 +00:00
doc: clarify window-id, tab-id, nvim_set_current_x #32528
Problem: Descriptions are somewhat vague. nvim_set_current_line modifies contents but nvim_set_current_buf does not, etc. Solution: - Make it clear that these functions accept or return a winid/tabid by linking to that concept in help. - Only these few files use the term "handles", so replace them with the more conventional terminology. - Add a new help section for tab-ID. This concept is unique to neovim because vim exposes tabnr, but not tab handles. This section is modelled after `:h winid`.
This commit is contained in:
@@ -214,7 +214,7 @@
|
||||
///
|
||||
/// @param[out] err Error details, if any
|
||||
///
|
||||
/// @return Window handle, or 0 on error
|
||||
/// @return |window-ID|, or 0 on error
|
||||
Window nvim_open_win(Buffer buffer, Boolean enter, Dict(win_config) *config, Error *err)
|
||||
FUNC_API_SINCE(6) FUNC_API_TEXTLOCK_ALLOW_CMDWIN
|
||||
{
|
||||
@@ -387,7 +387,7 @@ static int win_split_flags(WinSplit split, bool toplevel)
|
||||
///
|
||||
/// @see |nvim_open_win()|
|
||||
///
|
||||
/// @param window Window handle, or 0 for current window
|
||||
/// @param window |window-ID|, or 0 for current window
|
||||
/// @param config Map defining the window configuration,
|
||||
/// see |nvim_open_win()|
|
||||
/// @param[out] err Error details, if any
|
||||
@@ -694,7 +694,7 @@ static void config_put_bordertext(Dict(win_config) *config, WinConfig *fconfig,
|
||||
///
|
||||
/// `relative` is empty for normal windows.
|
||||
///
|
||||
/// @param window Window handle, or 0 for current window
|
||||
/// @param window |window-ID|, or 0 for current window
|
||||
/// @param[out] err Error details, if any
|
||||
/// @return Map defining the window configuration, see |nvim_open_win()|
|
||||
Dict(win_config) nvim_win_get_config(Window window, Arena *arena, Error *err)
|
||||
|
Reference in New Issue
Block a user