diff options
author | Josh Rahm <rahm@google.com> | 2021-09-23 18:02:25 -0600 |
---|---|---|
committer | Josh Rahm <rahm@google.com> | 2021-10-05 02:20:00 -0600 |
commit | 264c6c463811f45c2a66e0ac948c49657c57b3ac (patch) | |
tree | a5ce8f15f9daaf6256014cbca148ce821a03bcbe /src/nvim/window.c | |
parent | aba397991b59dbadad21b9ab7ad9f7a3a21f6259 (diff) | |
download | rneovim-264c6c463811f45c2a66e0ac948c49657c57b3ac.tar.gz rneovim-264c6c463811f45c2a66e0ac948c49657c57b3ac.tar.bz2 rneovim-264c6c463811f45c2a66e0ac948c49657c57b3ac.zip |
Add the ability to title floating windows.
The window title is set using the {title} key on the FloatConfig.
The window title allows for 3 different positions as defined
by the {title_position} key in the FloatConfig:
- left
- center
- right
The title also supports StatusLine-style highlighting using
the %#<HL># keys.
Diffstat (limited to 'src/nvim/window.c')
-rw-r--r-- | src/nvim/window.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/nvim/window.c b/src/nvim/window.c index 400962f993..a0ddd580b2 100644 --- a/src/nvim/window.c +++ b/src/nvim/window.c @@ -2785,6 +2785,11 @@ static win_T *win_free_mem(win_T *win, int *dirp, tabpage_T *tp) wp = firstwin; } } + xfree(win->w_float_config.title); + xfree(win->w_float_config.title_hl); + win->w_float_config.title_hl = NULL; + win->w_float_config.title = NULL; + win->w_float_config.n_title = 0; win_free(win, tp); // When deleting the current window of another tab page select a new |