Make a Tkinter Toplevel active

前端 未结 6 1357
灰色年华
灰色年华 2020-12-10 08:57

I am trying to make a Toplevel widget that is the active window on the screen (I want it so that if you press Enter, it exits the window. I already h

6条回答
  •  轮回少年
    2020-12-10 09:18

    I tried the above solutions and found that focus_force() alone worked on Windows Vista/Python 3.3. Also it may help to include the takefocus=True method while creating your Toplevel window.

提交回复
热议问题