From 5eb30c1543a4f9201a1c6d6039d38c32646bcf0a Mon Sep 17 00:00:00 2001 From: nicm <nicm> Date: Mon, 17 Mar 2025 20:33:20 +0000 Subject: [PATCH 1/2] Handle padding cells correctly for regular expression searching, GitHub issue 4399 from github at jyn dot dev. --- window-copy.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/window-copy.c b/window-copy.c index 7dcc8432..3a4f59bb 100644 --- a/window-copy.c +++ b/window-copy.c @@ -4263,6 +4263,8 @@ window_copy_match_at_cursor(struct window_copy_mode_data *data) buf = xrealloc(buf, len + 2); buf[len] = '\t'; len++; + } else if (gc.flags & GRID_FLAG_PADDING) { + /* nothing to do */ } else { buf = xrealloc(buf, len + gc.data.size + 1); memcpy(buf + len, gc.data.data, gc.data.size); From 817b621d2078137b4ddea78835f609a9d7bac339 Mon Sep 17 00:00:00 2001 From: nicm <nicm> Date: Mon, 17 Mar 2025 20:43:29 +0000 Subject: [PATCH 2/2] If there is an active query, set escape time temporarily to a higher value (the old default - 500). Some Windows terminals are very slow to respond, or the network may be slow. From github at jyn dot dev. --- tty-keys.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/tty-keys.c b/tty-keys.c index 45175171..7b0da5a2 100644 --- a/tty-keys.c +++ b/tty-keys.c @@ -937,6 +937,11 @@ partial_key: delay = options_get_number(global_options, "escape-time"); if (delay == 0) delay = 1; + if ((tty->flags & TTY_ALL_REQUEST_FLAGS) != TTY_ALL_REQUEST_FLAGS) { + log_debug("%s: increasing delay for active DA query", c->name); + if (delay < 500) + delay = 500; + } tv.tv_sec = delay / 1000; tv.tv_usec = (delay % 1000) * 1000L;