hovering over canvas item tkinter event

Solutions on MaxInterview for hovering over canvas item tkinter event by the best coders in the world

showing results for - "hovering over canvas item tkinter event"
Jessica
02 Sep 2016
1You can pass the argument activefill when creating your rectangle.
2
3From effboot.org:
4
5Fill color to use when the mouse pointer is moved over the item, if different from fill.
6
7To do so, replace:
8
9rectangle = self.canvas.create_rectangle(x, y, x + 50, y + 50, fill='red')
10By:
11
12rectangle = self.canvas.create_rectangle(x, y, x + 50, y + 50, fill='red', activefill='cyan')