Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 3235300

Browse files
authored
Merge pull request #7546 from anntzer/add-deprecation-messages
Deprecate update_datalim_numerix & update_from_data.
2 parents d67e3e8 + 491cce3 commit 3235300

File tree

2 files changed

+6
-4
lines changed

2 files changed

+6
-4
lines changed

lib/matplotlib/axes/_base.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1941,6 +1941,7 @@ def update_datalim(self, xys, updatex=True, updatey=True):
19411941
updatex=updatex, updatey=updatey)
19421942
self.ignore_existing_data_limits = False
19431943

1944+
@cbook.deprecated('2.0', alternative='update_datalim')
19441945
def update_datalim_numerix(self, x, y):
19451946
"""
19461947
Update the data lim bbox with seq of xy tups

lib/matplotlib/transforms.py

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -42,6 +42,7 @@
4242
import weakref
4343
import warnings
4444

45+
from . import cbook
4546
from .path import Path
4647

4748
DEBUG = False
@@ -857,19 +858,19 @@ def __repr__(self):
857858
def ignore(self, value):
858859
"""
859860
Set whether the existing bounds of the box should be ignored
860-
by subsequent calls to :meth:`update_from_data` or
861-
:meth:`update_from_data_xy`.
861+
by subsequent calls to :meth:`update_from_data_xy`.
862862
863863
*value*:
864864
865-
- When True, subsequent calls to :meth:`update_from_data`
865+
- When True, subsequent calls to :meth:`update_from_data_xy`
866866
will ignore the existing bounds of the :class:`Bbox`.
867867
868-
- When False, subsequent calls to :meth:`update_from_data`
868+
- When False, subsequent calls to :meth:`update_from_data_xy`
869869
will include the existing bounds of the :class:`Bbox`.
870870
"""
871871
self._ignore = value
872872

873+
@cbook.deprecated('2.0', alternative='update_from_data_xy')
873874
def update_from_data(self, x, y, ignore=None):
874875
"""
875876
Update the bounds of the :class:`Bbox` based on the passed in

0 commit comments

Comments
 (0)