J
Jerry
Hi,
I am (today!) starting to Python...
I am runnin MacOS X 10.3.3 with:
1) "Batteries included" Aqua Tcl/Tk version 8.4.5
2) The 2.3 version of Python that comes with the OS
3) The "Panther Additions for MacOS X" package
I have used the package manager to install Tkinter. I ran a couple of
examples and Tkinter seems to work.
I tried installing via the package manage the PIL package and trying
to do anything with jpegs fails....I noticed that I did not have libjpeg
installed. I got the jpg-6b package and created libjpeg.dylib in /usr/local/lib.
I tore out the PIL stuff from /Library and reinstalled the PIL package via
the package manager....I still get failures when trying to display a jpeg
file ( format not recognized...)
Here is a simple program I am trying to use...
#!/usr/bin/python
from Tkinter import *
import Image
import sys
def main():
filename = sys.argv[1]
root = Tk()
img = PhotoImage(file=filename)
label = Label(root, image=img)
label.pack()
root.mainloop()
main()
The program will do gifs ok...
How can I get jpeg support going?
Jerry
I am (today!) starting to Python...
I am runnin MacOS X 10.3.3 with:
1) "Batteries included" Aqua Tcl/Tk version 8.4.5
2) The 2.3 version of Python that comes with the OS
3) The "Panther Additions for MacOS X" package
I have used the package manager to install Tkinter. I ran a couple of
examples and Tkinter seems to work.
I tried installing via the package manage the PIL package and trying
to do anything with jpegs fails....I noticed that I did not have libjpeg
installed. I got the jpg-6b package and created libjpeg.dylib in /usr/local/lib.
I tore out the PIL stuff from /Library and reinstalled the PIL package via
the package manager....I still get failures when trying to display a jpeg
file ( format not recognized...)
Here is a simple program I am trying to use...
#!/usr/bin/python
from Tkinter import *
import Image
import sys
def main():
filename = sys.argv[1]
root = Tk()
img = PhotoImage(file=filename)
label = Label(root, image=img)
label.pack()
root.mainloop()
main()
The program will do gifs ok...
How can I get jpeg support going?
Jerry