MCPcopy Index your code
hub / github.com/python/cpython / press

Method press

Lib/tkinter/dnd.py:240–246  ·  view source on GitHub ↗
(self, event)

Source from the content-addressed store, hash-verified

238 label.destroy()
239
240 def press(self, event):
241 if dnd_start(self, event):
242 # where the pointer is relative to the label widget:
243 self.x_off = event.x
244 self.y_off = event.y
245 # where the widget is relative to the canvas:
246 self.x_orig, self.y_orig = self.canvas.coords(self.id)
247
248 def move(self, event):
249 x, y = self.where(self.canvas, event)

Callers

nothing calls this directly

Calls 2

dnd_startFunction · 0.85
coordsMethod · 0.45

Tested by

no test coverage detected