Instead of setting the popup default colours in the draw callback, set

it up in popup_display and follow the same routine as panes in the draw
and init_ctx callbacks - use the palette if the option value is default.
Allows application-set fg and bg to work in panes again.
This commit is contained in:
nicm
2021-10-25 09:22:17 +00:00
parent 9b4148b12c
commit 0cca695d6e
3 changed files with 48 additions and 39 deletions

7
tty.c
View File

@ -1972,10 +1972,9 @@ tty_cmd_cell(struct tty *tty, const struct tty_ctx *ctx)
for (i = 0; i < OVERLAY_MAX_RANGES; i++)
vis += r.nx[i];
if (vis < gcp->data.width) {
tty_draw_line(tty, s, s->cx, s->cy,
gcp->data.width, px, py, &ctx->defaults,
ctx->palette);
return;
tty_draw_line(tty, s, s->cx, s->cy, gcp->data.width,
px, py, &ctx->defaults, ctx->palette);
return;
}
}