diff -r 107746bd83f0 config.def.h --- a/config.def.h Fri Oct 05 18:30:01 2007 +0200 +++ b/config.def.h Sat Oct 06 10:27:54 2007 +0200 @@ -10,6 +10,8 @@ #define SELBORDERCOLOR "#0066ff" #define SELBGCOLOR "#0066ff" #define SELFGCOLOR "#ffffff" +#define FLOATNORMBORDERCOLOR NORMBORDERCOLOR +#define FLOATSELBORDERCOLOR SELBORDERCOLOR /* tagging */ const char tags[][MAXTAGLEN] = { "1", "2", "3", "4", "5", "6", "7", "8", "www" }; diff -r 107746bd83f0 dwm.c --- a/dwm.c Fri Oct 05 18:30:01 2007 +0200 +++ b/dwm.c Sat Oct 06 10:27:54 2007 +0200 @@ -51,7 +51,7 @@ /* enums */ enum { BarTop, BarBot, BarOff }; /* bar position */ enum { CurNormal, CurResize, CurMove, CurLast }; /* cursor */ -enum { ColBorder, ColFG, ColBG, ColLast }; /* color */ +enum { ColBorder, ColFG, ColBG, ColBorderFloat, ColLast }; /* color */ enum { NetSupported, NetWMName, NetLast }; /* EWMH atoms */ enum { WMProtocols, WMDelete, WMName, WMState, WMLast };/* default atoms */ @@ -689,7 +689,10 @@ focus(Client *c) { for(c = stack; c && !isvisible(c); c = c->snext); if(sel && sel != c) { grabbuttons(sel, False); - XSetWindowBorder(dpy, sel->win, dc.norm[ColBorder]); + if(sel->isfloating) + XSetWindowBorder(dpy, sel->win, dc.norm[ColBorderFloat]); + else + XSetWindowBorder(dpy, sel->win, dc.norm[ColBorder]); } if(c) { detachstack(c); @@ -701,7 +704,10 @@ focus(Client *c) { if(!selscreen) return; if(c) { - XSetWindowBorder(dpy, c->win, dc.sel[ColBorder]); + if(c->isfloating) + XSetWindowBorder(dpy, c->win, dc.sel[ColBorderFloat]); + else + XSetWindowBorder(dpy, c->win, dc.sel[ColBorder]); XSetInputFocus(dpy, c->win, RevertToPointerRoot, CurrentTime); } else @@ -1475,9 +1481,11 @@ setup(void) { dc.norm[ColBorder] = getcolor(NORMBORDERCOLOR); dc.norm[ColBG] = getcolor(NORMBGCOLOR); dc.norm[ColFG] = getcolor(NORMFGCOLOR); + dc.norm[ColBorderFloat] = getcolor(FLOATNORMBORDERCOLOR); dc.sel[ColBorder] = getcolor(SELBORDERCOLOR); dc.sel[ColBG] = getcolor(SELBGCOLOR); dc.sel[ColFG] = getcolor(SELFGCOLOR); + dc.sel[ColBorderFloat] = getcolor(FLOATSELBORDERCOLOR); initfont(FONT); dc.h = bh = dc.font.height + 2;