Enlightenment CVS committal

Author  : raster
Project : e17
Module  : libs/evas

Dir     : e17/libs/evas/src/lib/canvas


Modified Files:
        evas_object_text.c 


Log Message:


clip colors apply to style colors now too

===================================================================
RCS file: 
/cvsroot/enlightenment/e17/libs/evas/src/lib/canvas/evas_object_text.c,v
retrieving revision 1.44
retrieving revision 1.45
diff -u -3 -r1.44 -r1.45
--- evas_object_text.c  26 Nov 2005 13:58:33 -0000      1.44
+++ evas_object_text.c  26 Nov 2005 15:56:51 -0000      1.45
@@ -1221,8 +1221,7 @@
 
    /* render object to surface with context, and offxet by x,y */
    o = (Evas_Object_Text *)(obj->object_data);
-   ENFN->context_multiplier_unset(output,
-                                                          context);
+   ENFN->context_multiplier_unset(output, context);
 /*
    ENFN->context_color_set(output,
                                                    context,
@@ -1236,19 +1235,26 @@
                                                 obj->cur.cache.geometry.h);
  */
 
-#define COLOR_SET(object, sub, col) \
+#define COLOR_ONLY_SET(object, sub, col) \
        ENFN->context_color_set(output, context, \
                                object->sub.col.r, \
                                object->sub.col.g, \
                                object->sub.col.b, \
                                object->sub.col.a);
 
+#define COLOR_SET(object, sub, col) \
+       ENFN->context_color_set(output, context, \
+                               ((int)object->sub.col.r * 
((int)obj->cur.clipper->cur.cache.clip.r + 1)) >> 8, \
+                               ((int)object->sub.col.g * 
((int)obj->cur.clipper->cur.cache.clip.g + 1)) >> 8, \
+                               ((int)object->sub.col.b * 
((int)obj->cur.clipper->cur.cache.clip.b + 1)) >> 8, \
+                               ((int)object->sub.col.a * 
((int)obj->cur.clipper->cur.cache.clip.a + 1)) >> 8);
+
 #define COLOR_SET_AMUL(object, sub, col, amul) \
        ENFN->context_color_set(output, context, \
-                               object->sub.col.r, \
-                               object->sub.col.g, \
-                               object->sub.col.b, \
-                               ((int)object->sub.col.a * (amul)) / 255);
+                               ((int)object->sub.col.r * 
((int)obj->cur.clipper->cur.cache.clip.r + 1)) >> 8, \
+                               ((int)object->sub.col.g * 
((int)obj->cur.clipper->cur.cache.clip.g + 1)) >> 8, \
+                               ((int)object->sub.col.b * 
((int)obj->cur.clipper->cur.cache.clip.b + 1)) >> 8, \
+                               ((((int)object->sub.col.a * 
((int)obj->cur.clipper->cur.cache.clip.a + 1)) >> 8) * amul) / 255);
 
 #define DRAW_TEXT(ox, oy) \
    if ((o->engine_data) && (o->cur.text)) \
@@ -1357,7 +1363,7 @@
      }
 
    /* normal text */
-   COLOR_SET(obj, cur.cache, clip);
+   COLOR_ONLY_SET(obj, cur.cache, clip);
    DRAW_TEXT(0, 0);
 }
 




-------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc. Do you grep through log files
for problems?  Stop!  Download the new AJAX search engine that makes
searching your log files as easy as surfing the  web.  DOWNLOAD SPLUNK!
http://ads.osdn.com/?ad_id=7637&alloc_id=16865&op=click
_______________________________________________
enlightenment-cvs mailing list
enlightenment-cvs@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-cvs

Reply via email to