Update the bounds of the :class:`Bbox` based on the passed in data. After updating, the bounds will have positive *width* and *height*; *x0* and *y0* will be the minimal values. Parameters ---------- path : :class:`~matplotlib.path.Path` ig
(self, path, ignore=None, updatex=True, updatey=True)
| 853 | self._ignore = value |
| 854 | |
| 855 | def update_from_path(self, path, ignore=None, updatex=True, updatey=True): |
| 856 | """ |
| 857 | Update the bounds of the :class:`Bbox` based on the passed in |
| 858 | data. After updating, the bounds will have positive *width* |
| 859 | and *height*; *x0* and *y0* will be the minimal values. |
| 860 | |
| 861 | Parameters |
| 862 | ---------- |
| 863 | path : :class:`~matplotlib.path.Path` |
| 864 | |
| 865 | ignore : bool, optional |
| 866 | - when ``True``, ignore the existing bounds of the :class:`Bbox`. |
| 867 | - when ``False``, include the existing bounds of the :class:`Bbox`. |
| 868 | - when ``None``, use the last value passed to :meth:`ignore`. |
| 869 | |
| 870 | updatex, updatey : bool, optional |
| 871 | When ``True``, update the x/y values. |
| 872 | """ |
| 873 | if ignore is None: |
| 874 | ignore = self._ignore |
| 875 | |
| 876 | if path.vertices.size == 0: |
| 877 | return |
| 878 | |
| 879 | points, minpos, changed = update_path_extents( |
| 880 | path, None, self._points, self._minpos, ignore) |
| 881 | |
| 882 | if changed: |
| 883 | self.invalidate() |
| 884 | if updatex: |
| 885 | self._points[:, 0] = points[:, 0] |
| 886 | self._minpos[0] = minpos[0] |
| 887 | if updatey: |
| 888 | self._points[:, 1] = points[:, 1] |
| 889 | self._minpos[1] = minpos[1] |
| 890 | |
| 891 | def update_from_data_xy(self, xy, ignore=None, updatex=True, updatey=True): |
| 892 | """ |
no test coverage detected