config: add [csd].hide-when-maximized=yes|no

When enabled, the CSD titlebar will be hidden when the window is
maximized.

Closes #1019
This commit is contained in:
Daniel Eklöf 2022-04-15 20:12:34 +02:00
parent 979f48a62f
commit fbcebd4f1c
No known key found for this signature in database
GPG key ID: 5BBD4992C116573F
6 changed files with 19 additions and 2 deletions

View file

@ -1768,7 +1768,8 @@ bool
wayl_win_csd_titlebar_visible(const struct wl_window *win)
{
return win->csd_mode == CSD_YES &&
!win->is_fullscreen;
!win->is_fullscreen &&
!(win->is_maximized && win->term->conf->csd.hide_when_maximized);
}
bool