Revision: 7226
          http://matplotlib.svn.sourceforge.net/matplotlib/?rev=7226&view=rev
Author:   leejjoon
Date:     2009-06-19 04:33:44 +0000 (Fri, 19 Jun 2009)

Log Message:
-----------
fix sf bug 2806283 (patch by Joonas Paalasmaa)

Modified Paths:
--------------
    trunk/matplotlib/lib/matplotlib/colorbar.py

Modified: trunk/matplotlib/lib/matplotlib/colorbar.py
===================================================================
--- trunk/matplotlib/lib/matplotlib/colorbar.py 2009-06-17 02:18:39 UTC (rev 
7225)
+++ trunk/matplotlib/lib/matplotlib/colorbar.py 2009-06-19 04:33:44 UTC (rev 
7226)
@@ -29,6 +29,7 @@
 import matplotlib.patches as patches
 import matplotlib.collections as collections
 import matplotlib.contour as contour
+import matplotlib.artist as martist
 
 make_axes_kw_doc = '''
 
@@ -626,9 +627,10 @@
         self.mappable = mappable
         kw['cmap'] = mappable.cmap
         kw['norm'] = mappable.norm
-        kw['alpha'] = mappable.get_alpha()
+
         if isinstance(mappable, contour.ContourSet):
             CS = mappable
+            kw['alpha'] = mappable.get_alpha()
             kw['boundaries'] = CS._levels
             kw['values'] = CS.cvalues
             kw['extend'] = CS.extend
@@ -639,6 +641,9 @@
             if not CS.filled:
                 self.add_lines(CS)
         else:
+            if isinstance(mappable, martist.Artist):
+                kw['alpha'] = mappable.get_alpha()
+
             ColorbarBase.__init__(self, ax, **kw)
 
 


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

------------------------------------------------------------------------------
Crystal Reports - New Free Runtime and 30 Day Trial
Check out the new simplified licensing option that enables unlimited
royalty-free distribution of the report engine for externally facing 
server and web deployment.
http://p.sf.net/sfu/businessobjects
_______________________________________________
Matplotlib-checkins mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/matplotlib-checkins

Reply via email to