From 642cc15b9946b0281f34e889cde80b810f4fb130 Mon Sep 17 00:00:00 2001 From: nicm Date: Wed, 3 Jun 2026 20:16:14 +0000 Subject: [PATCH 1/2] Change so panes scroll when the cursor is at the top instead of halfway down, from Michael Grant. --- tty.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tty.c b/tty.c index 2d1ea01d..e3c620be 100644 --- a/tty.c +++ b/tty.c @@ -999,7 +999,7 @@ tty_window_offset1(struct tty *tty, u_int *ox, u_int *oy, u_int *sx, u_int *sy) else if (cy > w->sy - *sy) *oy = w->sy - *sy; else - *oy = cy - *sy / 2; + *oy = cy - *sy + 1; } c->pan_window = NULL; From 580f9ced08a4960692cd0ef813ae4fdbd89c8743 Mon Sep 17 00:00:00 2001 From: nicm Date: Wed, 3 Jun 2026 20:18:49 +0000 Subject: [PATCH 2/2] Change run-shell expansion to just be #{1} etc not #1 which interferes with colours. --- format.c | 9 +-------- tmux.1 | 3 --- 2 files changed, 1 insertion(+), 11 deletions(-) diff --git a/format.c b/format.c index a5afd282..75771630 100644 --- a/format.c +++ b/format.c @@ -5598,7 +5598,7 @@ format_expand1(struct format_expand_state *es, const char *fmt) const char *ptr, *s, *style_end = NULL; size_t off, len, n, outlen; int ch, brackets; - char expanded[8192], number[2] = { 0 }; + char expanded[8192]; if (fmt == NULL || *fmt == '\0' || !format_check_time(es)) return (xstrdup("")); @@ -5727,13 +5727,6 @@ format_expand1(struct format_expand_state *es, const char *fmt) continue; default: s = NULL; - if (ch >= '1' && ch <= '9') { - number[0] = ch; - if (format_replace(es, number, 1, &buf, &len, - &off) != 0) - break; - continue; - } if (fmt > style_end) { /* skip inside #[] */ if (ch >= 'A' && ch <= 'Z') s = format_upper[ch - 'A']; diff --git a/tmux.1 b/tmux.1 index c8c7dd41..9c9b38de 100644 --- a/tmux.1 +++ b/tmux.1 @@ -7868,9 +7868,6 @@ section. If .Ar argument values are given, they are available as -.Ql #1 , -.Ql #2 -or .Ql #{1} , .Ql #{2} and so on.