Skip to content

Commit

Permalink
wxGUI/psmap: fix simple point graphic recalculate position (#3164)
Browse files Browse the repository at this point in the history
Rectangle widget with integer coordinates Offset() method dx, dy
parameters require integer argument type.
  • Loading branch information
tmszi committed Sep 19, 2023
1 parent d76435c commit da8b418
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions gui/wxpython/psmap/frame.py
Original file line number Diff line number Diff line change
Expand Up @@ -2133,8 +2133,8 @@ def RecalculatePosition(self, ids):
rect=rect, canvasToPaper=True
)
rect.Offset(
dx=rect.GetWidth() / 2,
dy=rect.GetHeight() / 2,
dx=int(rect.GetWidth() / 2),
dy=int(rect.GetHeight() / 2),
)
self.instruction[id]["where"] = self.CanvasPaperCoordinates(
rect=rect, canvasToPaper=True
Expand Down

0 comments on commit da8b418

Please sign in to comment.