MCPcopy Create free account
hub / github.com/Image-Py/imagepy / mouse_move

Method mouse_move

imagepy/tools/Standard/magic_tol.py:77–87  ·  view source on GitHub ↗
(self, ips, x, y, btn, **key)

Source from the content-addressed store, hash-verified

75 ips.update()
76
77 def mouse_move(self, ips, x, y, btn, **key):
78 if ips.roi==None:return
79 lim = 5.0/key['canvas'].get_scale()
80 if btn==None:
81 self.cursor = wx.CURSOR_CROSS
82 if ips.roi.snap(x, y, ips.cur, lim)!=None:
83 self.cursor = wx.CURSOR_HAND
84 elif btn==1:
85 if self.curobj: ips.roi.draged(self.odx, self.ody, x, y, ips.cur, self.curobj)
86 ips.update()
87 self.odx, self.ody = x, y
88
89 def mouse_wheel(self, ips, x, y, d, **key):
90 pass

Callers

nothing calls this directly

Calls 4

get_scaleMethod · 0.80
snapMethod · 0.45
dragedMethod · 0.45
updateMethod · 0.45

Tested by

no test coverage detected