Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit 2b0f3dc

Browse files
authored
Merge pull request matplotlib#30382 from timhoffm/collection-autolim
MNT: Remove explicit use of default value add_collection(..., autolim=True)
2 parents a797f94 + 7224090 commit 2b0f3dc

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

‎lib/matplotlib/axes/_axes.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3043,7 +3043,7 @@ def broken_barh(self, xranges, yrange, align="bottom", **kwargs):
30433043
vertices.append([(x0, y0), (x0, y1), (x1, y1), (x1, y0)])
30443044

30453045
col = mcoll.PolyCollection(np.array(vertices), **kwargs)
3046-
self.add_collection(col, autolim=True)
3046+
self.add_collection(col)
30473047

30483048
return col
30493049

@@ -5821,7 +5821,7 @@ def quiver(self, *args, **kwargs):
58215821
# Make sure units are handled for x and y values
58225822
args = self._quiver_units(args, kwargs)
58235823
q = mquiver.Quiver(self, *args, **kwargs)
5824-
self.add_collection(q, autolim=True)
5824+
self.add_collection(q)
58255825
return q
58265826

58275827
# args can be some combination of X, Y, U, V, C and all should be replaced
@@ -5832,7 +5832,7 @@ def barbs(self, *args, **kwargs):
58325832
# Make sure units are handled for x and y values
58335833
args = self._quiver_units(args, kwargs)
58345834
b = mquiver.Barbs(self, *args, **kwargs)
5835-
self.add_collection(b, autolim=True)
5835+
self.add_collection(b)
58365836
return b
58375837

58385838
# Uses a custom implementation of data-kwarg handling in

‎lib/matplotlib/tests/test_collections.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -524,7 +524,7 @@ def test_regularpolycollection_rotate():
524524
col = mcollections.RegularPolyCollection(
525525
4, sizes=(100,), rotation=alpha,
526526
offsets=[xy], offset_transform=ax.transData)
527-
ax.add_collection(col, autolim=True)
527+
ax.add_collection(col)
528528

529529

530530
@image_comparison(['regularpolycollection_scale.png'], remove_text=True)
@@ -552,7 +552,7 @@ def get_transform(self):
552552
circle_areas = [np.pi / 2]
553553
squares = SquareCollection(
554554
sizes=circle_areas, offsets=xy, offset_transform=ax.transData)
555-
ax.add_collection(squares, autolim=True)
555+
ax.add_collection(squares)
556556
ax.axis([-1, 1, -1, 1])
557557

558558

0 commit comments

Comments
(0)

AltStyle によって変換されたページ (->オリジナル) /