Closed
Description
Bug report
Bug summary
When patch.get_path() contains a CLOSEPOLY vertex, the coordinates of that point are not part of that path. But _update_patch_limits still uses these points in updating the data limits. patches.Wedge creates such points that are outside the region of the patch.
Code for reproduction
from matplotlib import patches
from matplotlib import pyplot
f = pyplot.figure()
a = f.add_subplot()
a.add_patch(patches.Wedge((0,-1.0),1.05,60,120,0.1))
a.relim()
a.autoscale_view(True)
f.show()
Actual outcome
# If applicable, paste the console output here
#
#
Expected outcome
The lower limit of the y axis should not be so far from the actual painted region.
Matplotlib version
- Operating system: Arch Linux
- Matplotlib version: 3.3.3
- Matplotlib backend (
print(matplotlib.get_backend())
): Qt5Agg - Python version: 3.9.0
- Jupyter version (if applicable):
- Other libraries:
Installed via pacman