소스 검색

- some fixes on the app.jump_to() method for the Legacy(2D) graphic mode

Marius Stanciu 6 년 전
부모
커밋
b771cbd110
2개의 변경된 파일8개의 추가작업 그리고 2개의 파일을 삭제
  1. 7 2
      FlatCAMApp.py
  2. 1 0
      README.md

+ 7 - 2
FlatCAMApp.py

@@ -7362,10 +7362,15 @@ class App(QtCore.QObject):
             # in pixels where the origin 0,0 is in the lowest left point of the display window (in our case is the
             # canvas) and the point (width, height) is in the top-right location
             loc = self.plotcanvas.axes.transData.transform_point(location)
-            j_pos = (x0 + loc[0], y0 - loc[1])
+            j_pos = (
+                int(x0 + loc[0]),
+                int(y0 - loc[1])
+            )
             cursor.setPos(j_pos[0], j_pos[1])
+            self.plotcanvas.mouse = [location[0], location[1]]
+            self.plotcanvas.draw_cursor(x_pos=location[0], y_pos=location[1])
 
-        if self.grid_status() == True:
+        if self.grid_status():
             # Update cursor
             self.app_cursor.set_data(np.asarray([(location[0], location[1])]),
                                      symbol='++', edge_color=self.cursor_color_3D,

+ 1 - 0
README.md

@@ -24,6 +24,7 @@ CAD program, and create G-Code for Isolation routing.
 - updated the languages PO files
 - some fixes on the app.jump_to() method
 - made sure that the ToolFilm will not start saving a file if there are no objects loaded
+- some fixes on the app.jump_to() method for the Legacy(2D) graphic mode
 
 8.12.2019