[Tkinter-discuss] Any way to extract from an event object the event specifier string which fired the event?

Kenneth McDonald kenneth.m.mcdonald at sbcglobal.net
Sat May 8 20:11:10 EDT 2004

Let's say I have defined and bound a function to be executed
in response to an event:

def callback(e):

When the function is called, e is an event object from which I
can extract various bits of info; for example, e.widget is the
widget on which the binding was invoked.

However, I can't figure out any way to get the event string
specifying the firing event, i.e. the string by which 'callback'
was originally bound. From looking at Tk bind docs, this seems to
be a Tk lack rather than a Tkinter lack, but I'm wondering if
there is some other function in Tkinter/Tk which will let me
do this.


More information about the Tkinter-discuss mailing list