[Image-SIG] A small thing with PIL and the tk and tcl libraries.
BJörn Lindqvist
bjourne at gmail.com
Tue Dec 7 23:55:46 CET 2004
This program:
from Tkinter import *
import Image, ImageTk
class App(Frame):
def __init__(self, master = None):
Frame.__init__(self, master)
im = Image.open("tile0000.png")
self.pi = ImageTk.PhotoImage(im)
Button(self, text = "tjaba", image = self.pi).pack()
self.pi.paste(im)
self.pack()
if __name__ == "__main__":
app = App()
app.mainloop()
Gave the following exception:
Traceback (most recent call last):
File "test1.py", line 15, in ?
app = App()
File "test1.py", line 11, in __init__
self.pi.paste(im)
File "/usr/lib/python2.3/site-packages/PIL/ImageTk.py", line 179, in paste
import _imagingtk
ImportError: libtcl8.3.so: cannot open shared object file: No such file or
directory
But I have libtcl8.4.so in /usr/lib. I fixed it by making a symlink to
libtcl8.3.so. Minor inconvenience but annoying. :)
--
mvh Björn
More information about the Image-SIG
mailing list