8000 Doc: Fix Bbox and BboxBase links (#15229) · matplotlib/matplotlib@6675e8c · GitHub
[go: up one dir, main page]

Skip to content

Commit 6675e8c

Browse files
timhoffmImportanceOfBeingErnest
authored andcommitted
Doc: Fix Bbox and BboxBase links (#15229)
1 parent 59d71e4 commit 6675e8c

File tree

8 files changed

+19
-52
lines changed

8 files changed

+19
-52
lines changed

doc/missing-references.json

Lines changed: 2 additions & 35 deletions
Original file line numberDiff line numberDiff line change
@@ -91,8 +91,6 @@
9191
"Artist": [
9292
"doc/api/animation_api.rst:27:<autosummary>:1",
9393
"lib/matplotlib/animation.py:docstring of matplotlib.animation.ArtistAnimation:2",
94-
"lib/matplotlib/text.py:docstring of matplotlib.text.OffsetFrom:28",
95-
"lib/matplotlib/text.py:docstring of matplotlib.text.OffsetFrom:31",
9694
"lib/mpl_toolkits/axisartist/axisline_style.py:docstring of mpl_toolkits.axisartist.axisline_style.AxislineStyle:9"
9795
],
9896
"matplotlib.animation.Artis 10000 tAnimation.new_frame_seq": [
@@ -791,32 +789,6 @@
791789
"lib/mpl_toolkits/axisartist/axis_artist.py:docstring of mpl_toolkits.axisartist.axis_artist.AxisArtist.get_tightbbox:2",
792790
"lib/mpl_toolkits/mplot3d/art3d.py:docstring of mpl_toolkits.mplot3d.art3d.Text3D.get_tightbbox:2"
793791
],
794-
"BBox": [
795-
"lib/matplotlib/axes/_axes.py:docstring of matplotlib.axes.Axes:26",
796-
"lib/matplotlib/axes/_axes.py:docstring of matplotlib.axes.Axes:30",
797-
"lib/matplotlib/collections.py:docstring of matplotlib.collections.AsteriskPolygonCollection.get_tightbbox:26",
798-
"lib/matplotlib/collections.py:docstring of matplotlib.collections.BrokenBarHCollection.get_tightbbox:26",
799-
"lib/matplotlib/collections.py:docstring of matplotlib.collections.CircleCollection.get_tightbbox:26",
800-
"lib/matplotlib/collections.py:docstring of matplotlib.collections.Collection.get_tightbbox:26",
801-
"lib/matplotlib/collections.py:docstring of matplotlib.collections.EllipseCollection.get_tightbbox:26",
802-
"lib/matplotlib/collections.py:docstring of matplotlib.collections.EventCollection.get_tightbbox:26",
803-
"lib/matplotlib/collections.py:docstring of matplotlib.collections.LineCollection.get_tightbbox:26",
804-
"lib/matplotlib/collections.py:docstring of matplotlib.collections.PatchCollection.get_tightbbox:26",
805-
"lib/matplotlib/collections.py:docstring of matplotlib.collections.PathCollection.get_tightbbox:26",
806-
"lib/matplotlib/collections.py:docstring of matplotlib.collections.PolyCollection.get_tightbbox:26",
807-
"lib/matplotlib/collections.py:docstring of matplotlib.collections.QuadMesh.get_tightbbox:26",
808-
"lib/matplotlib/collections.py:docstring of matplotlib.collections.RegularPolyCollection.get_tightbbox:26",
809-
"lib/matplotlib/collections.py:docstring of matplotlib.collections.StarPolygonCollection.get_tightbbox:26",
810-
"lib/matplotlib/collections.py:docstring of matplotlib.collections.TriMesh.get_tightbbox:26",
811-
"lib/mpl_toolkits/axisartist/axis_artist.py:docstring of mpl_toolkits.axisartist.axis_artist.AxisArtist.get_tightbbox:26",
812-
"lib/mpl_toolkits/mplot3d/art3d.py:docstring of mpl_toolkits.mplot3d.art3d.Text3D.get_tightbbox:26"
813-
],
814-
"Bbox": [
815-
"lib/matplotlib/text.py:docstring of matplotlib.text.Annotation.get_window_extent:2",
816-
"lib/matplotlib/text.py:docstring of matplotlib.text.Text.get_window_extent:2",
817-
"lib/mpl_toolkits/axisartist/axis_artist.py:docstring of mpl_toolkits.axisartist.axis_artist.AxisLabel.get_window_extent:2",
818-
"lib/mpl_toolkits/axisartist/axis_artist.py:docstring of mpl_toolkits.axisartist.axis_artist.LabelBase.get_window_extent:2"
819-
],
820792
"'auto'": [
821793
"lib/matplotlib/ticker.py:docstring of matplotlib.ticker.MaxNLocator:28",
822794
"lib/mpl_toolkits/axisartist/grid_finder.py:docstring of mpl_toolkits.axisartist.grid_finder.MaxNLocator:8"
@@ -1774,14 +1746,9 @@
17741746
"pytest.mark.usefixtures": [
17751747
"lib/matplotlib/testing/decorators.py:docstring of matplotlib.testing.decorators.image_comparison:13"
17761748
],
1777-
"BboxBase": [
1778-
"lib/matplotlib/text.py:docstring of matplotlib.text.OffsetFrom:28",
1779-
"lib/matplotlib/text.py:docstring of matplotlib.text.OffsetFrom:31"
1780-
],
17811749
"Transform": [
17821750
"doc/users/prev_whats_new/whats_new_2.2.rst:357",
1783-
"doc/users/prev_whats_new/whats_new_2.2.rst:360",
1784-
"lib/matplotlib/text.py:docstring of matplotlib.text.OffsetFrom:28"
1751+
"doc/users/prev_whats_new/whats_new_2.2.rst:360"
17851752
],
17861753
"texmanager.TexManager": [
17871754
"lib/matplotlib/textpath.py:docstring of matplotlib.textpath.TextToPath.get_texmanager:2"
@@ -3888,4 +3855,4 @@
38883855
"doc/users/prev_whats_new/whats_new_1.5.rst:737"
38893856
]
38903857
}
3891-
}
3858+
}

lib/matplotlib/artist.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -276,7 +276,7 @@ def get_tightbbox(self, renderer):
276276
277277
Returns
278278
-------
279-
bbox : `.BBox`
279+
bbox : `.Bbox`
280280
The enclosing bounding box (in figure pixel co-ordinates).
281281
"""
282282
bbox = self.get_window_extent(renderer)

lib/matplotlib/axes/_axes.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -106,9 +106,9 @@ class Axes(_AxesBase):
106106
107107
Attributes
108108
----------
109-
dataLim : `.BBox`
109+
dataLim : `.Bbox`
110110
The bounding box enclosing all data displayed in the Axes.
111-
viewLim : `.BBox`
111+
viewLim : `.Bbox`
112112
The view limits in data coordinates.
113113
114114
"""

lib/matplotlib/axes/_base.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2008,17 +2008,17 @@ def relim(self, visible_only=False):
20082008

20092009
def update_datalim(self, xys, updatex=True, updatey=True):
20102010
"""
2011-
Extend the `~.Axes.dataLim` BBox to include the given points.
2011+
Extend the `~.Axes.dataLim` Bbox to include the given points.
20122012
2013-
If no data is set currently, the BBox will ignore its limits and set
2013+
If no data is set currently, the Bbox will ignore its limits and set
20142014
the bound to be the bounds of the xydata (*xys*). Otherwise, it will
20152015
compute the bounds of the union of its current data and the data in
20162016
*xys*.
20172017
20182018
Parameters
20192019
----------
20202020
xys : 2D array-like
2021-
The points to include in the data limits BBox. This can be either
2021+
The points to include in the data limits Bbox. This can be either
20222022
a list of (x, y) tuples or a Nx2 array.
20232023
20242024
updatex, updatey : bool, optional, default *True*
@@ -2033,7 +2033,7 @@ def update_datalim(self, xys, updatex=True, updatey=True):
20332033

20342034
def update_datalim_bounds(self, bounds):
20352035
"""
2036-
Extend the `~.Axes.datalim` BBox to include the given
2036+
Extend the `~.Axes.datalim` Bbox to include the given
20372037
`~matplotlib.transforms.Bbox`.
20382038
20392039
Parameters

lib/matplotlib/legend.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -367,8 +367,8 @@ def __init__(self, parent, handles, labels,
367367
Notes
368368
-----
369369
Users can specify any arbitrary location for the legend using the
370-
*bbox_to_anchor* keyword argument. bbox_to_anchor can be an instance
371-
of BboxBase(or its derivatives) or a tuple of 2 or 4 floats.
370+
*bbox_to_anchor* keyword argument. *bbox_to_anchor* can be a
371+
`.BboxBase` (or derived therefrom) or a tuple of 2 or 4 floats.
372372
See :meth:`set_bbox_to_anchor` for more detail.
373373
374374
The legend location can be specified by setting *loc* with a tuple of

lib/matplotlib/text.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -866,7 +866,7 @@ def get_verticalalignment(self):
866866

867867
def get_window_extent(self, renderer=None, dpi=None):
868868
"""
869-
Return the `Bbox` bounding the text, in display units.
869+
Return the `.Bbox` bounding the text, in display units.
870870
871871
In addition to being used internally, this is useful for specifying
872872
clickable regions in a png file on a web page.
@@ -1671,11 +1671,11 @@ def __init__(self, artist, ref_coord, unit="points"):
16711671
'''
16721672
Parameters
16731673
----------
1674-
artist : `Artist`, `BboxBase`, or `Transform`
1674+
artist : `.Artist`, `.BboxBase`, or `.Transform`
16751675
The object to compute the offset from.
16761676
16771677
ref_coord : length 2 sequence
1678-
If *artist* is an `Artist` or `BboxBase`, this values is
1678+
If *artist* is an `.Artist` or `.BboxBase`, this values is
16791679
the location to of the offset origin in fractions of the
16801680
*artist* bounding box.
16811681
@@ -2379,7 +2379,7 @@ def draw(self, renderer):
23792379

23802380
def get_window_extent(self, renderer=None):
23812381
"""
2382-
Return the `Bbox` bounding the text and arrow, in display units.
2382+
Return the `.Bbox` bounding the text and arrow, in display units.
23832383
23842384
Parameters
23852385
----------

lib/matplotlib/transforms.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -449,7 +449,7 @@ def overlaps(self, other):
449449
450450
Parameters
451451
----------
452-
other : BboxBase
452+
other : `.BboxBase`
453453
"""
454454
ax1, ay1, ax2, ay2 = self.extents
455455
bx1, by1, bx2, by2 = other.extents
@@ -490,7 +490,7 @@ def fully_overlaps(self, other):
490490
491491
Parameters
492492
----------
493-
other : BboxBase
493+
other : `.BboxBase`
494494
"""
495495
ax1, ay1, ax2, ay2 = self.extents
496496
bx1, by1, bx2, by2 = other.extents
@@ -644,7 +644,7 @@ def count_overlaps(self, bboxes):
644644
645645
Parameters
646646
----------
647-
bboxes : sequence of :class:`BboxBase` objects
647+
bboxes : sequence of `.BboxBase`
648648
"""
649649
return count_bboxes_overlapping_bbox(
650650
self, np.atleast_3d([np.array(x) for x in bboxes]))

lib/mpl_toolkits/axes_grid1/inset_locator.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -514,7 +514,7 @@ def inset_axes(parent_axes, width, height, loc='upper right',
514514
if len(bbox_to_anchor) != 4:
515515
raise ValueError("Using relative units for width or height "
516516
"requires to provide a 4-tuple or a "
517-
"`BBox` instance to `bbox_to_anchor.")
517+
"`Bbox` instance to `bbox_to_anchor.")
518518

519519
axes_locator = AnchoredSizeLocator(bbox_to_anchor,
520520
width, height,

0 commit comments

Comments
 (0)
0