Change so that window_flags escapes # automatically which means configs

will not have to change. A new format window_raw_flags contains the old
unescaped version.
This commit is contained in:
nicm
2021-01-20 07:16:54 +00:00
parent 0730dce5ab
commit fb774b77d0
7 changed files with 31 additions and 25 deletions

View File

@ -803,15 +803,18 @@ window_destroy_panes(struct window *w)
}
const char *
window_printable_flags(struct winlink *wl)
window_printable_flags(struct winlink *wl, int escape)
{
struct session *s = wl->session;
static char flags[32];
int pos;
pos = 0;
if (wl->flags & WINLINK_ACTIVITY)
if (wl->flags & WINLINK_ACTIVITY) {
flags[pos++] = '#';
if (escape)
flags[pos++] = '#';
}
if (wl->flags & WINLINK_BELL)
flags[pos++] = '!';
if (wl->flags & WINLINK_SILENCE)