Removes deprecated setResult() calls in matplotlib