You can change the dictionary plt.rcParams . For example, to disable the "s" key combination for the "Save Picture" button:
>>> import matplotlib.pyplot as plt >>> plt.rcParams['keymap.save'] 's' >>> plt.rcParams['keymap.save'] = ''
If you want the changes to be applied globally / permanently, then edit the matplotlibrc file and restart the Python interpreter. You can find the location of the configuration file on your system by calling a helper function:
>>> matplotlib.matplotlib_fname() '/Users/wim/.matplotlib/matplotlibrc'
wim
source share