simplified no Tk() sets _default_root

This commit is contained in:
Guido van Rossum 1995-09-07 19:45:52 +00:00
parent 55618efad9
commit bbf817557f
1 changed files with 1 additions and 2 deletions

View File

@ -4,9 +4,8 @@ import sys
def main():
filename = sys.argv[1]
root = Tk()
label = Label(root)
img = PhotoImage(file=filename)
label['image'] = img
label = Label(root, image=img)
label.pack()
root.mainloop()