Canvas - Rectangle. Is there an easy way to detect if you're inside?

Gordon Airport uce at ftc.gov
Thu Sep 11 20:27:01 EDT 2003


Have you tried find_closest?
Given a click event...

x = cv.canvasx( event.x )
y = cv.canvasy( event.y )
cvid = cv.find_closest( x, y )[0]
cv.itemconfig( cvid, fill = 'black' )






More information about the Python-list mailing list