Add a format for the name of the pane's mode, lets it be used as a

conditional for key bindings.
This commit is contained in:
nicm
2017-05-07 22:27:57 +00:00
parent d52f579fd5
commit 5fee4638e0
6 changed files with 21 additions and 8 deletions

View File

@ -1371,6 +1371,9 @@ format_defaults_pane(struct format_tree *ft, struct window_pane *wp)
}
format_add(ft, "pane_in_mode", "%d", wp->screen != &wp->base);
if (wp->mode != NULL)
format_add(ft, "pane_mode", "%s", wp->mode->name);
format_add(ft, "pane_synchronized", "%d",
!!options_get_number(wp->window->options, "synchronize-panes"));
format_add(ft, "pane_search_string", "%s",