diff --git a/lib/matplotlib/backend_bases.py b/lib/matplotlib/backend_bases.py index ab1c2bf1a6ef..2158990f578a 100644 --- a/lib/matplotlib/backend_bases.py +++ b/lib/matplotlib/backend_bases.py @@ -678,7 +678,8 @@ def _draw_disabled(self): cost of the draw_XYZ calls on the canvas. """ no_ops = { - meth_name: lambda *args, **kwargs: None + meth_name: functools.update_wrapper(lambda *args, **kwargs: None, + getattr(RendererBase, meth_name)) for meth_name in dir(RendererBase) if (meth_name.startswith("draw_") or meth_name in ["open_group", "close_group"])