@@ -4354,17 +4354,15 @@ def get_mutation_aspect(self):
43544354 else 1 ) # backcompat.
43554355
43564356 def get_path (self ):
4357- """
4358- Return the path of the arrow in the data coordinates. Use
4359- get_path_in_displaycoord() method to retrieve the arrow path
4360- in display coordinates.
4361- """
4362- _path , fillable = self .get_path_in_displaycoord ()
4357+ """Return the path of the arrow in the data coordinates."""
4358+ # The path is generated in display coordinates, then converted back to
4359+ # data coordinates.
4360+ _path , fillable = self ._get_path_in_displaycoord ()
43634361 if np .iterable (fillable ):
43644362 _path = Path .make_compound_path (* _path )
43654363 return self .get_transform ().inverted ().transform_path (_path )
43664364
4367- def get_path_in_displaycoord (self ):
4365+ def _get_path_in_displaycoord (self ):
43684366 """Return the mutated path of the arrow in display coordinates."""
43694367 dpi_cor = self ._dpi_cor
43704368
@@ -4389,18 +4387,22 @@ def get_path_in_displaycoord(self):
43894387
43904388 return _path , fillable
43914389
4390+ get_path_in_displaycoord = _api .deprecate_privatize_attribute (
4391+ "3.5" ,
4392+ alternative = "self.get_transform().transform_path(self.get_path())" )
4393+
43924394 def draw (self , renderer ):
43934395 if not self .get_visible ():
43944396 return
43954397
43964398 with self ._bind_draw_path_function (renderer ) as draw_path :
43974399
43984400 # FIXME : dpi_cor is for the dpi-dependency of the linewidth. There
4399- # could be room for improvement. Maybe get_path_in_displaycoord
4401+ # could be room for improvement. Maybe _get_path_in_displaycoord
44004402 # could take a renderer argument, but get_path should be adapted
44014403 # too.
44024404 self ._dpi_cor = renderer .points_to_pixels (1. )
4403- path , fillable = self .get_path_in_displaycoord ()
4405+ path , fillable = self ._get_path_in_displaycoord ()
44044406
44054407 if not np .iterable (fillable ):
44064408 path = [path ]
@@ -4612,7 +4614,7 @@ def get_annotation_clip(self):
46124614 """
46134615 return self ._annotation_clip
46144616
4615- def get_path_in_displaycoord (self ):
4617+ def _get_path_in_displaycoord (self ):
46164618 """Return the mutated path of the arrow in display coordinates."""
46174619 dpi_cor = self ._dpi_cor
46184620 posA = self ._get_xy (self .xy1 , self .coords1 , self .axesA )
0 commit comments