|
From: <ef...@us...> - 2009-08-08 06:07:14
|
Revision: 7424
http://matplotlib.svn.sourceforge.net/matplotlib/?rev=7424&view=rev
Author: efiring
Date: 2009-08-08 06:07:06 +0000 (Sat, 08 Aug 2009)
Log Message:
-----------
Restore default colormap behavior: no color (alpha = 0) for masked data
Modified Paths:
--------------
branches/v0_99_maint/lib/matplotlib/colors.py
Modified: branches/v0_99_maint/lib/matplotlib/colors.py
===================================================================
--- branches/v0_99_maint/lib/matplotlib/colors.py 2009-08-08 02:06:56 UTC (rev 7423)
+++ branches/v0_99_maint/lib/matplotlib/colors.py 2009-08-08 06:07:06 UTC (rev 7424)
@@ -488,7 +488,10 @@
if not self._isinit: self._init()
alpha = min(alpha, 1.0) # alpha must be between 0 and 1
alpha = max(alpha, 0.0)
- self._lut[:,-1] = alpha
+ self._lut[:-1,-1] = alpha # Don't assign global alpha to i_bad;
+ # it would defeat the purpose of the
+ # default behavior, which is to not
+ # show anything where data are missing.
mask_bad = None
if not cbook.iterable(X):
vtype = 'scalar'
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|