Key action: A Key,keyaction,from Tkinter
Key action: A Key,keyaction,from Tkinter
from Tkinter import *def onArrowKey(event): print 'Got key press'tkroot = Tk()labelfont = ('courier', 20, 'bold') widget = Label(tkroot, text='Hello bind world')widget.config(bg='red', font=labelfont) widget.config(height=5, width=20) widget.pack(expand=YES, fill=BOTH)widget.bind('<A>', onArrowKey) widget.focus() tkroot.title('Click Me')tkroot.mainloop()
- Mouse button differentiation: Mouse click,,from Tkinte
- Mouse button differentiation: Right Button click,,from
- Menu item mouse on (active) foreground color,mousefore
- Canvas paint program: drag and draw,canvasdrag,from Tk
- Draw Math Curve,drawmathcurve,from Tkinter
- Set Button style: font,buttonfont,from Tkinter
热门文章:
相关内容
- Mouse button differentiation: Mouse click,,from Tkinter
- Mouse button differentiation: Right Button click,,from Tkinter
- Menu item mouse on (active) foreground color,mouseforeground,from T
- Canvas paint program: drag and draw,canvasdrag,from Tkinter
- Draw Math Curve,drawmathcurve,from Tkinter
- Set Button style: font,buttonfont,from Tkinter
- List comprehensions: for and tuple,,print [x+y f
- Assignment to slices: Remove some,assignmentslices,a = ['spam',
- Use in to check Membership,checkmembership,permissions
- Change individual elements of a list,individualelements,a = ['spam'
评论关闭