-
-
Notifications
You must be signed in to change notification settings - Fork 2k
Closed
Labels
stubs: incompleteAnnotations or sub-modules missing from an existing package or moduleAnnotations or sub-modules missing from an existing package or module
Description
Hello,
Mypy complains that tkinter.Event doesn't have x_root/y_root attributes, which is incorrect.
Here is an example (abridged) of code that mypy complains about.
...
def show(self, event):
# Position the tooltip below and to the rigth of the cursor (16x16).
# Mypy returns an error Event has no attr x_root/y_root.
x_pos = event.x_root + 16 # type: ignore
y_pos = event.y_root + 16 # type: ignore
self.geometry('+{0}+{1}'.format(x_pos, y_pos))
self.deiconify()
self.visible = True
self.after(self.delay, self.hide) # Milliseconds.
...
widget.bind('<Enter>', self.show)
...
Best regards,
JM
Metadata
Metadata
Assignees
Labels
stubs: incompleteAnnotations or sub-modules missing from an existing package or moduleAnnotations or sub-modules missing from an existing package or module