mirror of
https://github.com/neovim/neovim.git
synced 2025-09-24 20:18:32 +00:00
feat(float): implement footer
Problem: Now way to show text at the bottom part of floating window border (a.k.a. "footer"). Solution: Allows `footer` and `footer_pos` config fields similar to `title` and `title_pos`.
This commit is contained in:
@@ -782,10 +782,17 @@ static void win_redr_border(win_T *wp)
|
||||
if (adj[3]) {
|
||||
grid_put_schar(grid, irow + adj[0], 0, chars[6], attrs[6]);
|
||||
}
|
||||
|
||||
for (int i = 0; i < icol; i++) {
|
||||
int ic = (i == 0 && !adj[3] && chars[6][0]) ? 6 : 5;
|
||||
grid_put_schar(grid, irow + adj[0], i + adj[3], chars[ic], attrs[ic]);
|
||||
}
|
||||
|
||||
if (wp->w_float_config.footer) {
|
||||
int footer_col = win_get_bordertext_col(icol, wp->w_float_config.footer_width,
|
||||
wp->w_float_config.footer_pos);
|
||||
win_redr_bordertext(wp, grid, wp->w_float_config.footer_chunks, grid->rows - 1, footer_col);
|
||||
}
|
||||
if (adj[1]) {
|
||||
grid_put_schar(grid, irow + adj[0], icol + adj[3], chars[4], attrs[4]);
|
||||
}
|
||||
|
Reference in New Issue
Block a user