From 75c874c55b4acae548706a8235f7a7ddc4a83cda Mon Sep 17 00:00:00 2001 From: nicm Date: Wed, 15 Jul 2026 12:45:39 +0000 Subject: [PATCH] Clear the "waiting for editor" area before writing so stray characters aren't visible from underneath. --- window-buffer.c | 4 +++- window-customize.c | 4 +++- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/window-buffer.c b/window-buffer.c index 17eae8f3c..e19f6205d 100644 --- a/window-buffer.c +++ b/window-buffer.c @@ -1,4 +1,4 @@ -/* $OpenBSD: window-buffer.c,v 1.50 2026/07/14 17:17:18 nicm Exp $ */ +/* $OpenBSD: window-buffer.c,v 1.51 2026/07/15 12:45:39 nicm Exp $ */ /* * Copyright (c) 2017 Nicholas Marriott @@ -525,6 +525,8 @@ window_buffer_draw_waiting(struct window_buffer_modedata *data) screen_write_start(&ctx, s); screen_write_cursormove(&ctx, x, y, 0); screen_write_box(&ctx, box_w, box_h, BOX_LINES_DEFAULT, &gc, NULL); + screen_write_cursormove(&ctx, x + 1, y + 1, 0); + screen_write_clearcharacter(&ctx, box_w - 2, gc.bg); screen_write_cursormove(&ctx, text_x, y + 1, 0); screen_write_nputs(&ctx, box_w - 2, &gc, "%s", text); screen_write_stop(&ctx); diff --git a/window-customize.c b/window-customize.c index 4f5ff8a9f..624ef21d7 100644 --- a/window-customize.c +++ b/window-customize.c @@ -1,4 +1,4 @@ -/* $OpenBSD: window-customize.c,v 1.34 2026/07/14 17:17:18 nicm Exp $ */ +/* $OpenBSD: window-customize.c,v 1.35 2026/07/15 12:45:39 nicm Exp $ */ /* * Copyright (c) 2020 Nicholas Marriott @@ -397,6 +397,8 @@ window_customize_draw_waiting(struct window_customize_modedata *data) screen_write_start(&ctx, s); screen_write_cursormove(&ctx, x, y, 0); screen_write_box(&ctx, box_w, box_h, BOX_LINES_DEFAULT, &gc, NULL); + screen_write_cursormove(&ctx, x + 1, y + 1, 0); + screen_write_clearcharacter(&ctx, box_w - 2, gc.bg); screen_write_cursormove(&ctx, text_x, y + 1, 0); screen_write_nputs(&ctx, box_w - 2, &gc, "%s", text); screen_write_stop(&ctx);