From a62545d8ff0b9c7f7c73cd93dc37f4a865c70809 Mon Sep 17 00:00:00 2001 From: "Jens H. Nielsen" Date: Fri, 16 Dec 2011 09:24:39 +0100 Subject: [PATCH] use pcolormesh instead of pcolor in axes_grid1 colorbar This is identical to the standard colorbar and removes artifacts in the pdf version of the plot. --- lib/mpl_toolkits/axes_grid1/colorbar.py | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/lib/mpl_toolkits/axes_grid1/colorbar.py b/lib/mpl_toolkits/axes_grid1/colorbar.py index ba56af317864..b60d6a9a9398 100644 --- a/lib/mpl_toolkits/axes_grid1/colorbar.py +++ b/lib/mpl_toolkits/axes_grid1/colorbar.py @@ -544,9 +544,8 @@ def _add_solids(self, X, Y, C): del self.solids del self.dividers - col = self.ax.pcolor(*args, **kw) - col.set_antialiased(False) # This is to suppress artifacts. We - # may use pcolormesh instead. + col = self.ax.pcolormesh(*args, **kw) + self.solids = col if self.drawedges: self.dividers = collections.LineCollection(self._edges(X,Y),