faqts : Computers : Programming : Languages : Python : Tkinter

+ Search
Add Entry AlertManage Folder Edit Entry Add page to http://del.icio.us/
Did You Find This Entry Useful?

3 of 6 people (50%) answered Yes
Recently 3 of 6 people (50%) answered Yes

Entry

How to bind a key <Control-C> to a widget?

Mar 22nd, 2006 22:28
Waldi Wolf, brian hako,


from Tkinter import *
root=Tk()
# An example for the root window widget
def click(ptr):
	print 'Control-C'
root.bind('<Control-c>',click)
root.mainloop()