From 9536fe9a83731d9172ff06b12957181974f12dd7 Mon Sep 17 00:00:00 2001 From: Antony Lee Date: Fri, 8 Feb 2019 19:25:37 +0100 Subject: [PATCH] Deprecate Spine.is_frame_like. It has never been used since its addition in the "smart bounds" commit in 2009 (a5761e821) and the implementation just seems overly complex (the `position == "center"` / `position == "zero"` checks have effectively no effect on the return value). If someone complains with a use case, we can always revisit... --- doc/api/next_api_changes/2019-02-08-AL.rst | 5 +++++ lib/matplotlib/spines.py | 1 + 2 files changed, 6 insertions(+) create mode 100644 doc/api/next_api_changes/2019-02-08-AL.rst diff --git a/doc/api/next_api_changes/2019-02-08-AL.rst b/doc/api/next_api_changes/2019-02-08-AL.rst new file mode 100644 index 000000000000..a43a5323d14e --- /dev/null +++ b/doc/api/next_api_changes/2019-02-08-AL.rst @@ -0,0 +1,5 @@ +Deprecations +```````````` + +``Spine.is_frame_like`` is deprecated. It has never been used in the codebase +since its addition in 2009. diff --git a/lib/matplotlib/spines.py b/lib/matplotlib/spines.py index 7eaa72f5c4c9..d5d3880b88d5 100644 --- a/lib/matplotlib/spines.py +++ b/lib/matplotlib/spines.py @@ -177,6 +177,7 @@ def cla(self): if self.axis is not None: self.axis.cla() + @cbook.deprecated("3.1") def is_frame_like(self): """return True if directly on axes frame