Update of /cvsroot/tmux/tmux
In directory sfp-cvsdas-2.v30.ch3.sourceforge.com:/tmp/cvs-serv612

Modified Files:
        cmd-set-option.c status.c tmux.1 tmux.c 
Log Message:
Sync OpenBSD patchset 701:

Colour+attribute options for status line alerts, from Alex Alexander.


Index: status.c
===================================================================
RCS file: /cvsroot/tmux/tmux/status.c,v
retrieving revision 1.147
retrieving revision 1.148
diff -u -d -r1.147 -r1.148
--- status.c    6 Apr 2010 21:45:36 -0000       1.147
+++ status.c    5 Jun 2010 23:56:29 -0000       1.148
@@ -595,8 +595,17 @@
 
        if (session_alert_has(s, wl, WINDOW_ACTIVITY) ||
            session_alert_has(s, wl, WINDOW_BELL) ||
-           session_alert_has(s, wl, WINDOW_CONTENT))
-               gc->attr ^= GRID_ATTR_REVERSE;
+           session_alert_has(s, wl, WINDOW_CONTENT)) {
+               fg = options_get_number(oo, "window-status-alert-fg");
+               if (fg != 8)
+                       colour_set_fg(gc, fg);
+               bg = options_get_number(oo, "window-status-alert-bg");
+               if (bg != 8)
+                       colour_set_bg(gc, bg);
+               attr = options_get_number(oo, "window-status-alert-attr");
+               if (attr != 0)
+                       gc->attr = attr;
+       }
 
        text = status_replace(c, wl, fmt, t, 1);
        return (text);

Index: tmux.c
===================================================================
RCS file: /cvsroot/tmux/tmux/tmux.c,v
retrieving revision 1.208
retrieving revision 1.209
diff -u -d -r1.208 -r1.209
--- tmux.c      16 May 2010 17:50:31 -0000      1.208
+++ tmux.c      5 Jun 2010 23:56:29 -0000       1.209
@@ -419,6 +419,9 @@
        options_set_number(wo, "window-status-current-bg", 8);
        options_set_number(wo, "window-status-current-fg", 8);
        options_set_number(wo, "window-status-fg", 8);
+       options_set_number(wo, "window-status-alert-attr", GRID_ATTR_REVERSE);
+       options_set_number(wo, "window-status-alert-bg", 8);
+       options_set_number(wo, "window-status-alert-fg", 8);
        options_set_string(wo, "window-status-format", "#I:#W#F");
        options_set_string(wo, "window-status-current-format", "#I:#W#F");
        options_set_string(wo, "word-separators", " -_@");

Index: cmd-set-option.c
===================================================================
RCS file: /cvsroot/tmux/tmux/cmd-set-option.c,v
retrieving revision 1.96
retrieving revision 1.97
diff -u -d -r1.96 -r1.97
--- cmd-set-option.c    26 Feb 2010 13:31:39 -0000      1.96
+++ cmd-set-option.c    5 Jun 2010 23:56:29 -0000       1.97
@@ -157,6 +157,9 @@
        { "remain-on-exit", SET_OPTION_FLAG, 0, 0, NULL },
        { "synchronize-panes", SET_OPTION_FLAG, 0, 0, NULL },
        { "utf8", SET_OPTION_FLAG, 0, 0, NULL },
+       { "window-status-alert-attr", SET_OPTION_ATTRIBUTES, 0, 0, NULL },
+       { "window-status-alert-bg", SET_OPTION_COLOUR, 0, 0, NULL },
+       { "window-status-alert-fg", SET_OPTION_COLOUR, 0, 0, NULL },
        { "window-status-attr", SET_OPTION_ATTRIBUTES, 0, 0, NULL },
        { "window-status-bg", SET_OPTION_COLOUR, 0, 0, NULL },
        { "window-status-current-attr", SET_OPTION_ATTRIBUTES, 0, 0, NULL },

Index: tmux.1
===================================================================
RCS file: /cvsroot/tmux/tmux/tmux.1,v
retrieving revision 1.250
retrieving revision 1.251
diff -u -d -r1.250 -r1.251
--- tmux.1      5 Jun 2010 23:54:51 -0000       1.250
+++ tmux.1      5 Jun 2010 23:56:29 -0000       1.251
@@ -2073,6 +2073,16 @@
 The default is
 .Ql #I:#W#F .
 .Pp
+.It Ic window-status-alert-attr Ar attributes
+Set status line attributes for windows which have an alert (bell, activity
+or content).
+.Pp
+.It Ic window-status-alert-bg Ar colour
+Set status line background colour for windows with an alert.
+.Pp
+.It Ic window-status-alert-fg Ar colour
+Set status line foreground colour for windows with an alert.
+.Pp
 .It Ic window-status-current-attr Ar attributes
 Set status line attributes for the currently active window.
 .Pp


------------------------------------------------------------------------------
ThinkGeek and WIRED's GeekDad team up for the Ultimate 
GeekDad Father's Day Giveaway. ONE MASSIVE PRIZE to the 
lucky parental unit.  See the prize list and enter to win: 
http://p.sf.net/sfu/thinkgeek-promo
_______________________________________________
tmux-cvs mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/tmux-cvs

Reply via email to