Project

General

Profile

Revision 816:d52976b6ccfc

IDd52976b6ccfc
Parent 815:c0e5b3712092
Child 817:b1891bf5727b

Added by Maarten Sneep about 2 years ago

Remove deprecated access to internal dictionary

View differences:

src/matplotlib_colormaps.py
35 35
    # Get a list of the colormaps in matplotlib.  Ignore the ones that end with
36 36
    # '_r' because these are simply reversed versions of ones that don't end
37 37
    # with '_r'
38
    maps = [m for m in plt.cm.datad if not m.endswith("_r")]
39
    maps.extend([m for m in plt.cm.cmap_d if not m.endswith("_r")])
40
    maps = list(set(maps))
38
    maps = [m for m in plt.colormaps() if not m.endswith("_r")]
41 39
    maps.sort(key=lambda s: s.lower())
42 40
    return maps
43 41

  

Also available in: Unified diff