mirror of
https://github.com/python/cpython.git
synced 2025-11-01 02:38:53 +00:00
Initial revision
This commit is contained in:
parent
23d7b4bbfd
commit
c66394d049
1 changed files with 13 additions and 0 deletions
13
Demo/tkinter/guido/imageview.py
Executable file
13
Demo/tkinter/guido/imageview.py
Executable file
|
|
@ -0,0 +1,13 @@
|
|||
from Tkinter import *
|
||||
import sys
|
||||
|
||||
def main():
|
||||
filename = sys.argv[1]
|
||||
root = Tk()
|
||||
label = Label(root)
|
||||
img = PhotoImage(file=filename)
|
||||
label['image'] = img
|
||||
label.pack()
|
||||
root.mainloop()
|
||||
|
||||
main()
|
||||
Loading…
Add table
Add a link
Reference in a new issue