Skip to content

Commit

Permalink
horizon: use keyword arg for radius
Browse files Browse the repository at this point in the history
- Required in matplotlib==3.8.0 and later.

Signed-off-by: Rhys Mainwaring <rhys.mainwaring@me.com>
  • Loading branch information
srmainwaring authored and peterbarker committed Jan 4, 2024
1 parent aa38fe9 commit ef4f77a
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions MAVProxy/modules/lib/wxhorizon_ui.py
Original file line number Diff line number Diff line change
Expand Up @@ -173,7 +173,7 @@ def checkReszie(self):

def createHeadingPointer(self):
'''Creates the pointer for the current heading.'''
self.headingTri = patches.RegularPolygon((0.0,0.80),3,0.05,color='k',zorder=4)
self.headingTri = patches.RegularPolygon((0.0,0.80),3,radius=0.05,color='k',zorder=4)
self.axes.add_patch(self.headingTri)
self.headingText = self.axes.text(0.0,0.675,'0',color='k',size=self.fontSize,horizontalalignment='center',verticalalignment='center',zorder=4)

Expand All @@ -184,7 +184,7 @@ def adjustHeadingPointer(self):

def createNorthPointer(self):
'''Creates the north pointer relative to current heading.'''
self.headingNorthTri = patches.RegularPolygon((0.0,0.80),3,0.05,color='k',zorder=4)
self.headingNorthTri = patches.RegularPolygon((0.0,0.80),3,radius=0.05,color='k',zorder=4)
self.axes.add_patch(self.headingNorthTri)
self.headingNorthText = self.axes.text(0.0,0.675,'N',color='k',size=self.fontSize,horizontalalignment='center',verticalalignment='center',zorder=4)

Expand Down Expand Up @@ -434,7 +434,7 @@ def updateWPText(self):

def createWPPointer(self):
'''Creates the waypoint pointer relative to current heading.'''
self.headingWPTri = patches.RegularPolygon((0.0,0.55),3,0.05,facecolor='lime',zorder=4,ec='k')
self.headingWPTri = patches.RegularPolygon((0.0,0.55),3,radius=0.05,facecolor='lime',zorder=4,ec='k')
self.axes.add_patch(self.headingWPTri)
self.headingWPText = self.axes.text(0.0,0.45,'1',color='lime',size=self.fontSize,horizontalalignment='center',verticalalignment='center',zorder=4)
self.headingWPText.set_path_effects([PathEffects.withStroke(linewidth=1,foreground='k')])
Expand Down

0 comments on commit ef4f77a

Please sign in to comment.