[Tutor] Images + Tkinter

Hans Gubitz gubitz@netcologne.de
Sun Nov 17 12:33:01 2002


The thread has moved to python-de.


On Sun, Nov 17, 2002 at 04:44:06PM -0000, alan.gauld@bt.com wrote:
> > tk.mainloop() seems to be not in the right place. But the gif will not
> > be shown, when I eliminate this line.
> 
> Do the other window elements work?
> I tried your code without the canvas and it worked fine without the 
> tk.mainloop() line.
> 
> What exactly happens?
The image is not shown.


Martin v. Loewis sent the explanation:

>When you drop the last reference to an Tkinter.Image object, the image
>is destroyed. So always keep a reference to an image that you want to
>use.
>
>Regards,
>Martin


Gruß Hans 

-- 
Hans Gubitz <gubitz@netcologne.de>