本文主要思路:使用tkinter编写界面,使用3个Label组件和多线程技术实现学生名单的滚动显示。...root.destroy()
root.protocol('WM_DELETE_WINDOW', closeWindow)
# 模拟学生名单,可以加上数据库访问接口,从数据库中读取学生名单
students...'本次中奖:'+lbSecond['text'])
btnStop = tkinter.Button(root, text='停', command=btnStopClick)
btnStop.place...(root, text='')
lbFirst.place(x=80, y=60, width=100, height=20)
# 红色Label组件,表示中奖名单
lbSecond = tkinter.Label...(root, text='')
lbThird.place(x=80, y=120, width=100, height=20)
# 启动tkinter主程序
root.mainloop()
运行视频: