From 3d7b1876fe985147d8fe24b105aff0b7d24575ae Mon Sep 17 00:00:00 2001
From: Anish Athalye <me@anishathalye.com>
Date: Wed, 22 Oct 2014 07:42:05 -0400
Subject: [PATCH] Add format for reading pane inputoff

---
 format.c | 1 +
 tmux.1   | 1 +
 2 files changed, 2 insertions(+)

diff --git a/format.c b/format.c
index baf23ec..eac707d 100644
--- a/format.c
+++ b/format.c
@@ -554,6 +554,7 @@ format_window_pane(struct format_tree *ft, struct window_pane *wp)
 	format_add(ft, "pane_id", "%%%u", wp->id);
 	format_add(ft, "pane_active", "%d", wp == wp->window->active);
 	format_add(ft, "pane_dead", "%d", wp->fd == -1);
+	format_add(ft, "pane_inputoff", "%d", !!(wp->flags & PANE_INPUTOFF));
 
 	if (window_pane_visible(wp)) {
 		format_add(ft, "pane_left", "%u", wp->xoff);
diff --git a/tmux.1 b/tmux.1
index 8afc3c5..03c60f0 100644
--- a/tmux.1
+++ b/tmux.1
@@ -3103,6 +3103,7 @@ The following variables are available, where appropriate:
 .It Li "pane_height" Ta "" Ta "Height of pane"
 .It Li "pane_id" Ta "#D" Ta "Unique pane ID"
 .It Li "pane_in_mode" Ta "" Ta "If pane is in a mode"
+.It Li "pane_inputoff" Ta "" Ta "If input to pane is disabled"
 .It Li "pane_index" Ta "#P" Ta "Index of pane"
 .It Li "pane_left" Ta "" Ta "Left of pane"
 .It Li "pane_pid" Ta "" Ta "PID of first process in pane"
-- 
2.0.1

