diff --git a/src/conky.c b/src/conky.c index 8668d6d0..2fb16386 100644 --- a/src/conky.c +++ b/src/conky.c @@ -7845,13 +7845,16 @@ void clean_up(void *memtofree1, void* memtofree2) } #ifdef X11 if (x_initialised == YES) { + XClearArea(display, window.window, text_start_x - window.border_inner_margin - window.border_outer_margin - window.border_width, + text_start_y - window.border_inner_margin - window.border_outer_margin - window.border_width, + text_width + window.border_inner_margin * 2 + window.border_outer_margin * 2 + window.border_width * 2, + text_height + window.border_inner_margin * 2 + window.border_outer_margin * 2 + window.border_width * 2, 0); destroy_window(); free_fonts(); if(x11_stuff.region) { XDestroyRegion(x11_stuff.region); x11_stuff.region = NULL; } - XClearWindow(display, RootWindow(display, screen)); XCloseDisplay(display); display = NULL; if(info.x11.desktop.all_names) { diff --git a/src/x11.c b/src/x11.c index a5af2826..28f5e8d2 100644 --- a/src/x11.c +++ b/src/x11.c @@ -193,7 +193,6 @@ void set_transparent_background(Window win) XSetWindowBackground(display, win, background_colour); colour_set = background_colour; } - // XClearWindow(display, win); not sure why this was here } void destroy_window(void) @@ -478,15 +477,6 @@ void init_window(int own_window, int w, int h, int set_trans, int back_colour, #endif /* IMLIB2 */ XFlush(display); - /* set_transparent_background(window.window); - * must be done after double buffer stuff? */ -#ifdef OWN_WINDOW - /* if (own_window) { - set_transparent_background(window.window); - XClearWindow(display, window.window); - } */ -#endif - XSelectInput(display, window.window, ExposureMask | PropertyChangeMask #ifdef OWN_WINDOW | (own_window ? (StructureNotifyMask |