--- rxvt-unicode/src/rxvtfont.C 2008/01/07 12:41:31 1.127 +++ rxvt-unicode/src/rxvtfont.C 2008/01/23 05:59:29 1.130 @@ -1298,15 +1298,15 @@ int w = term->fwidth * len; int h = term->fheight; - /* TODO: this logic needs some more thinking, since we no longer do pseudo-transparency. + /* * Maybe make buffering into a resource flag? Compile time option doesn't seems like a * good idea from the perspective of packaging for wide variety of user configs. */ - bool buffered = true + bool buffered = bg >= Color_transparent; #ifdef FORCE_UNBUFFERED_XFT - && bg >= 0 + buffered = false; #endif - ; + // cut trailing spaces while (len && text [len - 1] == ' ') len--; @@ -1342,9 +1342,9 @@ if (buffered) { - bool back_rendered = false; if (ep != enc) { + bool back_rendered = false; rxvt_drawable &d2 = d.screen->scratch_drawable (w, h); #ifdef HAVE_BG_PIXMAP @@ -1352,12 +1352,12 @@ { Picture dst = 0; - if (bg >= 0 && term->pix_colors[bg].c.color.alpha < 0x0ff00) + if (bg >= 0 && term->pix_colors[bg].is_opaque ()) dst = XftDrawPicture (d2); - if (bg < 0 || dst != 0) + if (dst) { - int src_x = x, src_y = y ; + int src_x = x, src_y = y; if (term->bgPixmap.is_parentOrigin ()) {