python - Tkinter window won't update/refresh until I switch to another window (like finder) -
mac osx, python 2.7, tkinter
when programme runs , root window opens, input in entry field recorded, not displayed on screen...until 1. resize whole window manually, or 2. switch application window, finder or outlook, , switching root window.
from tkinter import * root = tk() root.attributes("-topmost", true) label1 = label(root, text="enter name: ") label2 = label(root, text="what's favorite color? ") entry1 = entry(root) entry2 = entry(root) label1.grid(row=0) label2.grid(row=1) entry1.grid(row=0, column=1) entry2.grid(row=1, column=1) #two options tried no avail #root.update_idletasks() #root.update() root.mainloop()
am programming incorrectly? (i took illustration youtube video worked) there incompatible computer , these software versions?
thanks taking look. i've searched everywhere , can't find other references of happening.
make sure using right tcl/tk osx version. mean 'recorded, not displayed '? if cannot see letter type, mean 'recorded'? code looks fine on win7 machine.
python python-2.7 tkinter
No comments:
Post a Comment