From 3546890578598090dbf1b33c10477e439fbf442f Mon Sep 17 00:00:00 2001 From: John Vogel Date: Wed, 28 May 2014 20:38:36 -0400 Subject: [PATCH] Clear all pixmaps at start of parse, but not at each ${S} command. --- bar.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/bar.c b/bar.c index 6346870..a40bfae 100644 --- a/bar.c +++ b/bar.c @@ -302,7 +302,8 @@ parse (char *text) memset(&astack, 0, sizeof(area_stack_t)); - fill_rect(cur_mon->pixmap, gc[GC_CLEAR], 0, 0, bw, bh); + for (monitor_t *m = monhead; m != NULL; m = m->next) + fill_rect(m->pixmap, gc[GC_CLEAR], 0, 0, m->width, bh); for (;;) { if (*p == '\0' || *p == '\n') @@ -356,7 +357,6 @@ parse (char *text) p++; pos_x = 0; - fill_rect(cur_mon->pixmap, gc[GC_CLEAR], 0, 0, cur_mon->width, bh); break; /* In case of error keep parsing after the closing } */