# mimic an animated GIF displaying a series of GIFs
# (an animated GIF was used to create the series of GIFs with a common GIF animator utility)
import time
from Tkinter import *
root = Tk()
imagelist = ["dog001.gif","dog002.gif","dog003.gif","dog004.gif","dog005.gif","dog006.gif","dog007.gif"]
# extract width and height info
photo1 = PhotoImage(file=imagelist[0])
width1 = photo1.width()
height1 = photo1.height()
canvas1 = Canvas(width=width1, height=height1)
canvas1.pack()
# loop through the series of GIFs
for k in range(0, 1000):
print imagelist[k%7], k # test only
photo1 = PhotoImage(file=imagelist[k%7])
canvas1.create_image(width1/2.0, height1/2.0, image=photo1)
canvas1.update()
time.sleep(0.1)
root.mainloop()