Difference between ACTIVE and NORMAL state

戏子无情 提交于 2021-02-20 17:03:23

问题


I have been using Tkinter from couple of weeks. One thing I have noticed is that the tkinter widgets (Button, etc.) have 3 states: NORMAL, ACTIVE and DISABLED. I understand the NORMAL and DISABLED states. Whats the difference between the ACTIVE and NORMAL states?


回答1:


Tk sets state = ACTIVE when a mouse is over a non-DISABLED button option (i.e. NORMAL) It can then be made to appear raised, sunken, flat, flash etc. So basically, NORMAL enables a button while ACTIVE can change the appearance settings on mouse over etc. Hope this helps, there's a great post about it here:

http://tkinter.unpythonic.net/wiki/Widgets/Button



来源:https://stackoverflow.com/questions/19125342/difference-between-active-and-normal-state

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!