fix(float): ensure relative window grid is allocated (#34459)

Problem:  Uninitialized grid for a "win" relative float when redrawing
          just after it has been opened.
Solution: Ensure window grid is allocated or assigned the default grid.
This commit is contained in:
luukvbaal
2025-06-12 08:51:29 +02:00
committed by GitHub
parent 5f00e6adaf
commit 66e4784f5a
2 changed files with 15 additions and 0 deletions

View File

@@ -844,6 +844,7 @@ void ui_ext_win_position(win_T *wp, bool validate)
}
int row_off = 0;
int col_off = 0;
win_grid_alloc(win);
grid = grid_adjust(&win->w_grid, &row_off, &col_off);
row += row_off;
col += col_off;