summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--cmd-display-panes.c15
-rw-r--r--tmux.15
2 files changed, 14 insertions, 6 deletions
diff --git a/cmd-display-panes.c b/cmd-display-panes.c
index 352b2e4d..64efb89a 100644
--- a/cmd-display-panes.c
+++ b/cmd-display-panes.c
@@ -34,8 +34,8 @@ const struct cmd_entry cmd_display_panes_entry = {
.name = "display-panes",
.alias = "displayp",
- .args = { "bd:t:", 0, 1 },
- .usage = "[-b] [-d duration] " CMD_TARGET_CLIENT_USAGE " [template]",
+ .args = { "bd:Nt:", 0, 1 },
+ .usage = "[-bN] [-d duration] " CMD_TARGET_CLIENT_USAGE " [template]",
.flags = CMD_AFTERHOOK|CMD_CLIENT_TFLAG,
.exec = cmd_display_panes_exec
@@ -284,8 +284,15 @@ cmd_display_panes_exec(struct cmd *self, struct cmdq_item *item)
else
cdata->item = item;
- server_client_set_overlay(tc, delay, NULL, NULL, cmd_display_panes_draw,
- cmd_display_panes_key, cmd_display_panes_free, cdata);
+ if (args_has(args, 'N')) {
+ server_client_set_overlay(tc, delay, NULL, NULL,
+ cmd_display_panes_draw, NULL, cmd_display_panes_free,
+ cdata);
+ } else {
+ server_client_set_overlay(tc, delay, NULL, NULL,
+ cmd_display_panes_draw, cmd_display_panes_key,
+ cmd_display_panes_free, cdata);
+ }
if (args_has(args, 'b'))
return (CMD_RETURN_NORMAL);
diff --git a/tmux.1 b/tmux.1
index 37f6f165..4cc4bfe4 100644
--- a/tmux.1
+++ b/tmux.1
@@ -2098,7 +2098,7 @@ starts without the option information.
This command works only if at least one client is attached.
.It Xo
.Ic display-panes
-.Op Fl b
+.Op Fl bN
.Op Fl d Ar duration
.Op Fl t Ar target-client
.Op Ar template
@@ -2111,7 +2111,8 @@ See the
and
.Ic display-panes-active-colour
session options.
-The indicator is closed when a key is pressed or
+The indicator is closed when a key is pressed (unless
+.Fl N is given) or
.Ar duration
milliseconds have passed.
If