diff --git a/patch/bar_status2d.c b/patch/bar_status2d.c index d7ae08f..48bccdf 100644 --- a/patch/bar_status2d.c +++ b/patch/bar_status2d.c @@ -61,6 +61,7 @@ drawstatusbar(int x, char* stext) short isCode = 0; char *text; char *p; + Clr oldbg, oldfg; len = strlen(stext) + 1; if (!(text = (char*) malloc(sizeof(char)*len))) die("malloc"); @@ -125,6 +126,17 @@ drawstatusbar(int x, char* stext) } else if (text[i] == 'd') { drw->scheme[ColFg] = scheme[SchemeNorm][ColFg]; drw->scheme[ColBg] = scheme[SchemeNorm][ColBg]; + } else if (text[i] == 'w') { + Clr swp; + swp = drw->scheme[ColFg]; + drw->scheme[ColFg] = drw->scheme[ColBg]; + drw->scheme[ColBg] = swp; + } else if (text[i] == 'v') { + oldfg = drw->scheme[ColFg]; + oldbg = drw->scheme[ColBg]; + } else if (text[i] == 't') { + drw->scheme[ColFg] = oldfg; + drw->scheme[ColBg] = oldbg; } else if (text[i] == 'r') { int rx = atoi(text + ++i); while (text[++i] != ',');