Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 346bb1a

Browse files
committed
FIX: make image.set_clim mark the figure as stale
Push the stale flag down into the ScalarMappable so that it gets applied to all ScalarMappable sub-classes (ex Collections).
1 parent b5238ac commit 346bb1a

File tree

2 files changed

+1
-8
lines changed

2 files changed

+1
-8
lines changed

lib/matplotlib/cm.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -375,3 +375,4 @@ def changed(self):
375375

376376
for key in self.update_dict:
377377
self.update_dict[key] = True
378+
self.stale = True

lib/matplotlib/image.py

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -192,14 +192,6 @@ def _interpdr(self):
192192
def iterpnames(self):
193193
return interpolations_names
194194

195-
def set_cmap(self, cmap):
196-
super(_ImageBase, self).set_cmap(cmap)
197-
self.stale = True
198-
199-
def set_norm(self, norm):
200-
super(_ImageBase, self).set_norm(norm)
201-
self.stale = True
202-
203195
def __str__(self):
204196
return "AxesImage(%g,%g;%gx%g)" % tuple(self.axes.bbox.bounds)
205197

0 commit comments

Comments
 (0)