fix(api): ensure win_get_config() "border" is reciprocal (#34322)

fix(api): ensure win_get_config() is reciprocal

Problem:  win_get_config() does not include a 'none' border field,
          causing nvim_open_win() to apply the 'winborder' value.
Solution: Include a 'none' border field in the returned config,
          such that it can be used reciprocally in nvim_open_win()
          to yield the same window layout.
This commit is contained in:
luukvbaal
2025-06-06 12:40:57 +02:00
committed by GitHub
parent 9f505b4d0f
commit 3165e94a64
2 changed files with 7 additions and 3 deletions

View File

@@ -768,6 +768,8 @@ Dict(win_config) nvim_win_get_config(Window window, Arena *arena, Error *err)
if (config->footer) {
config_put_bordertext(&rv, config, kBorderTextFooter, arena);
}
} else {
PUT_KEY_X(rv, border, STRING_OBJ(cstr_as_string("none")));
}
} else if (!config->external) {
PUT_KEY_X(rv, width, wp->w_width);