From cc4257d3968a327a7858ae69af07eb060748638a Mon Sep 17 00:00:00 2001 From: Thomas Kittelmann Date: Wed, 17 Jan 2024 09:57:13 +0100 Subject: [PATCH] fix simplehists plotutils --- .../data/pkgs/SimpleHists/SimpleHists/python/plotutils.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/simplebuild_dgcode/data/pkgs/SimpleHists/SimpleHists/python/plotutils.py b/src/simplebuild_dgcode/data/pkgs/SimpleHists/SimpleHists/python/plotutils.py index 2a573a7..b5468de 100644 --- a/src/simplebuild_dgcode/data/pkgs/SimpleHists/SimpleHists/python/plotutils.py +++ b/src/simplebuild_dgcode/data/pkgs/SimpleHists/SimpleHists/python/plotutils.py @@ -943,7 +943,7 @@ def _mpl_get_cmap( arg ): #Recommended since matplotlib 3.7: return matplotlib.colormaps.get_cmap( arg ) #Deprecated in matplotlib 3.7: - return matplotlib.cm.get_cmap(cm) + return matplotlib.cm.get_cmap(arg) def _has_cmap(cm): if cm in plt.cm.datad: @@ -1176,9 +1176,9 @@ def overlay(hists,labels,colors=None, else: fig,ax=figure,axes - if title!=False: ax.set_title(title)#not making dragable (center seems to be always the right choice) - if xlabel!=False: ax.set_xlabel(xlabel,picker=True)#todo: should snap to center/right ... - if ylabel!=False: ax.set_ylabel(ylabel,picker=True)#todo: ... or have a shortcut key + if title is False: ax.set_title(title)#not making dragable (center seems to be always the right choice) + if xlabel is False: ax.set_xlabel(xlabel,picker=True)#todo: should snap to center/right ... + if ylabel is False: ax.set_ylabel(ylabel,picker=True)#todo: ... or have a shortcut key lines=[] proxy_artists=[]