Revision: 8412
          http://matplotlib.svn.sourceforge.net/matplotlib/?rev=8412&view=rev
Author:   efiring
Date:     2010-06-11 08:09:25 +0000 (Fri, 11 Jun 2010)

Log Message:
-----------
[3014606] fix set_alpha in backend_cairo

Modified Paths:
--------------
    trunk/matplotlib/lib/matplotlib/backends/backend_cairo.py

Modified: trunk/matplotlib/lib/matplotlib/backends/backend_cairo.py
===================================================================
--- trunk/matplotlib/lib/matplotlib/backends/backend_cairo.py   2010-06-11 
07:23:54 UTC (rev 8411)
+++ trunk/matplotlib/lib/matplotlib/backends/backend_cairo.py   2010-06-11 
08:09:25 UTC (rev 8412)
@@ -140,8 +140,8 @@
 
 
     def draw_path(self, gc, path, transform, rgbFace=None):
-        if len(path.vertices) > 18980:   
-            raise ValueError("The Cairo backend can not draw paths longer than 
18980 points.")   
+        if len(path.vertices) > 18980:
+            raise ValueError("The Cairo backend can not draw paths longer than 
18980 points.")
 
         ctx = gc.ctx
 
@@ -315,9 +315,10 @@
 
 
     def set_alpha(self, alpha):
-        self._alpha = alpha
+        GraphicsContextBase.set_alpha(self, alpha)
+        _alpha = self.get_alpha()
         rgb = self._rgb
-        self.ctx.set_source_rgba (rgb[0], rgb[1], rgb[2], alpha)
+        self.ctx.set_source_rgba (rgb[0], rgb[1], rgb[2], _alpha)
 
 
     #def set_antialiased(self, b):


This was sent by the SourceForge.net collaborative development platform, the 
world's largest Open Source development site.

------------------------------------------------------------------------------
ThinkGeek and WIRED's GeekDad team up for the Ultimate 
GeekDad Father's Day Giveaway. ONE MASSIVE PRIZE to the 
lucky parental unit.  See the prize list and enter to win: 
http://p.sf.net/sfu/thinkgeek-promo
_______________________________________________
Matplotlib-checkins mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/matplotlib-checkins

Reply via email to