*** empty log message ***
authorroot <root>
Thu, 2 Nov 2006 17:23:50 +0000 (17:23 +0000)
committerroot <root>
Thu, 2 Nov 2006 17:23:50 +0000 (17:23 +0000)
Changes
src/rxvt.h
src/rxvtfont.C
src/screen.C

diff --git a/Changes b/Changes
index 5a8bc875149b70fd8e98a8dd8711c31336a4dbef..973b0928df528efa064934377a37fadbcc3a84b0 100644 (file)
--- a/Changes
+++ b/Changes
@@ -20,7 +20,6 @@ WISH: http://www120.pair.com/mccarthy/nextstep/intro.htmld/Workspace.html is the
 WISH: kick out xpm.C, replace by pixbuf
 DUMB: support tex fonts
 
-TODO: clear_rect -1 transparency breaks -ip
 8.0
        - combining characters cleared the area instead of creating an overlay,
           thus losing the ability to draw combining characters properly in most
index fc21f0f961e0cc1d83db28f76607a54cb4b65064..bb5e26b341d9d1370e46d34e0659121de10a0fbd 100644 (file)
@@ -522,6 +522,8 @@ enum {
  */
 
 enum colour_list {
+  Color_none = -2,
+  Color_transparent = -1,
   Color_fg = 0,
   Color_bg,
   minCOLOR,                   /* 2 */
index fd133d3fbe7da08ba142c6bff5446087a998a36e..ca8d0d7bd437b88365e8f13cf6b3084c4d13feb2 100644 (file)
@@ -234,7 +234,7 @@ rxvt_font::clear_rect (rxvt_drawable &d, int x, int y, int w, int h, int color)
   dTermDisplay;
   dTermGC;
   
-  if (color == Color_bg)
+  if (color == Color_bg || color == Color_transparent)
     XClearArea (disp, d, x, y, w, h, false);
   else if (color >= 0)
     {
@@ -443,7 +443,7 @@ rxvt_font_default::draw (rxvt_drawable &d, int x, int y,
                                 ? f1
                                 : (*fs)[fs->find_font (cc->c2)];
 
-              f2->draw (d, x, y, chrs, width, fg, -1);
+              f2->draw (d, x, y, chrs, width, fg, Color_none);
             }
         }
 #endif
index 28089c0fc4363a157e9244ca2630a12e20b22bfc..77b993575bac515382f42e4672b79cefecf90f1e 100644 (file)
@@ -2351,14 +2351,14 @@ rxvt_term::scr_refresh () NOTHROW
            */
           rxvt_font *font = (*fontset[GET_STYLE (rend)])[GET_FONT (rend)];
 
-          if (back == Color_bg && have_bg)
+          if (have_bg && back == Color_bg)
             {
               // this is very ugly, maybe push it into ->draw?
 
               for (i = 0; i < count; i++) /* don't draw empty strings */
                 if (text[i] != ' ')
                   {
-                    font->draw (*drawable, xpixel, ypixel, text, count, fore, -1);
+                    font->draw (*drawable, xpixel, ypixel, text, count, fore, Color_transparent);
                     goto did_clear;
                   }