Extend fill-character to allow inside and outside to be separate and use

a different default (filled characters rather than dots) for inside.
This commit is contained in:
nicm
2026-07-23 09:38:27 +00:00
committed by tmux update bot
parent 7277712ca8
commit 8862390c34
9 changed files with 111 additions and 54 deletions

View File

@@ -1,4 +1,4 @@
/* $OpenBSD: window.c,v 1.367 2026/07/21 13:04:01 nicm Exp $ */
/* $OpenBSD: window.c,v 1.368 2026/07/23 09:38:27 nicm Exp $ */
/*
* Copyright (c) 2007 Nicholas Marriott <nicholas.marriott@gmail.com>
@@ -439,8 +439,6 @@ window_create(u_int sx, u_int sy, u_int xpixel, u_int ypixel)
w->id = next_window_id++;
RB_INSERT(windows, &windows, w);
window_set_fill_character(w);
if (gettimeofday(&w->creation_time, NULL) != 0)
fatal("gettimeofday failed");
window_update_activity(w);
@@ -474,7 +472,6 @@ window_destroy(struct window *w)
event_del(&w->offset_timer);
options_free(w->options);
free(w->fill_character);
free(w->name);
free(w);
@@ -2431,25 +2428,6 @@ window_pane_update_used_data(struct window_pane *wp,
wpo->used += size;
}
void
window_set_fill_character(struct window *w)
{
const char *value;
struct utf8_data *ud;
free(w->fill_character);
w->fill_character = NULL;
value = options_get_string(w->options, "fill-character");
if (*value != '\0' && utf8_isvalid(value)) {
ud = utf8_fromcstr(value);
if (ud != NULL && ud[0].width == 1)
w->fill_character = ud;
else
free(ud);
}
}
void
window_pane_default_cursor(struct window_pane *wp)
{