aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authornicm <nicm>2014-09-08 14:29:05 +0000
committernicm <nicm>2014-09-08 14:29:05 +0000
commit9bda7e881a01af4deabeccc7a292d873c9c7f4e6 (patch)
tree70f7bd2c3fb0c25a12b17274b1841d147c79974c
parent8a473b57576a7deab9f498db1399b0d798fb45b2 (diff)
downloadrtmux-9bda7e881a01af4deabeccc7a292d873c9c7f4e6.tar.gz
rtmux-9bda7e881a01af4deabeccc7a292d873c9c7f4e6.tar.bz2
rtmux-9bda7e881a01af4deabeccc7a292d873c9c7f4e6.zip
Add window_last_flag and window_zoomed_flag. From John Morrissey.
-rw-r--r--format.c5
-rw-r--r--tmux.12
2 files changed, 6 insertions, 1 deletions
diff --git a/format.c b/format.c
index 400e4320..ed3c2037 100644
--- a/format.c
+++ b/format.c
@@ -494,7 +494,10 @@ format_winlink(struct format_tree *ft, struct session *s, struct winlink *wl)
!!(wl->flags & WINLINK_ACTIVITY));
format_add(ft, "window_silence_flag", "%u",
!!(wl->flags & WINLINK_SILENCE));
-
+ format_add(ft, "window_last_flag", "%u",
+ !!(wl == TAILQ_FIRST(&s->lastw)));
+ format_add(ft, "window_zoomed_flag", "%u",
+ !!(wl->flags & WINDOW_ZOOMED));
free(flags);
}
diff --git a/tmux.1 b/tmux.1
index e2ff7fc0..4e86e9c1 100644
--- a/tmux.1
+++ b/tmux.1
@@ -3132,11 +3132,13 @@ The following variables are available, where appropriate:
.It Li "window_height" Ta "" Ta "Height of window"
.It Li "window_id" Ta "" Ta "Unique window ID"
.It Li "window_index" Ta "#I" Ta "Index of window"
+.It Li "window_last_flag" Ta "" Ta "1 if window is the last used"
.It Li "window_layout" Ta "" Ta "Window layout description"
.It Li "window_name" Ta "#W" Ta "Name of window"
.It Li "window_panes" Ta "" Ta "Number of panes in window"
.It Li "window_silence_flag" Ta "" Ta "1 if window has silence alert"
.It Li "window_width" Ta "" Ta "Width of window"
+.It Li "window_zoomed_flag" Ta "" Ta "1 if window is zoomed"
.It Li "wrap_flag" Ta "" Ta "Pane wrap flag"
.El
.Sh NAMES AND TITLES