Re: [Tkinter-discuss] displaying an image

2012-10-04 Thread Lion Kimbro
The tkinter modules were renamed from 2-3. I can't remember where the table is that shows the renames/reorganization, but you need to know that the modules were renamed. In Python 3, it's "import tkinter". In Python 2, it's "import Tkinter". Other modules within the tkinter hierarchy w

Re: [Tkinter-discuss] displaying an image

2012-10-04 Thread Matthew Ngaha
> Are you running a tutorial for Python 2 from Python 3? sorry for the direct email. yes the tutorial uses Python 2, while i only have Python 3 ___ Tkinter-discuss mailing list Tkinter-discuss@python.org http://mail.python.org/mailman/listinfo/tkinter-

Re: [Tkinter-discuss] displaying an image

2012-10-04 Thread Lion Kimbro
Are you running a tutorial for Python 2 from Python 3? On Thu, Oct 4, 2012 at 12:29 PM, Matthew Ngaha wrote: > > import Tkinter as tk > > import ttk > > > i get an ImportError say no module named Tkinter:( > ___ > Tkinter-discuss mailing list > Tkint

Re: [Tkinter-discuss] displaying an image

2012-10-04 Thread Matthew Ngaha
> import Tkinter as tk > import ttk i get an ImportError say no module named Tkinter:( ___ Tkinter-discuss mailing list Tkinter-discuss@python.org http://mail.python.org/mailman/listinfo/tkinter-discuss

Re: [Tkinter-discuss] displaying an image

2012-10-04 Thread Lynn Oliver
I should be the one to apologize; I included code that is required for packages created by pyinstaller, which is a tool that will take a Python script and turn it into a self-contained executable. Let me try again: import Tkinter as tk import ttk photo = tk.PhotoImage(

Re: [Tkinter-discuss] displaying an image

2012-10-04 Thread Michael O'Donnell
You need to install PIL to use the tutorial you are doing. http://www.pythonware.com/products/pil/ PIL has some advantages to built in images within TKinter, especially if you are wanting to manipulate images rather than just display them Mick >> Hi Matthew, >> >> Your first line should in fact

Re: [Tkinter-discuss] displaying an image

2012-10-04 Thread Matthew Ngaha
On Thu, Oct 4, 2012 at 7:23 PM, Lynn Oliver wrote: > I know this isn't exactly what you asked, but I am displaying an image in a > label in a --onefile distribution, and this code works both while debugging > and while running the packaged application: > >if getattr(sys, 'frozen',

Re: [Tkinter-discuss] displaying an image

2012-10-04 Thread Lynn Oliver
I know this isn't exactly what you asked, but I am displaying an image in a label in a --onefile distribution, and this code works both while debugging and while running the packaged application: if getattr(sys, 'frozen', None): basedir = sys._MEIPASS el

Re: [Tkinter-discuss] displaying an image

2012-10-04 Thread Michael O'Donnell
Hi Matthew, Your first line should in fact be: from PIL import Image ...then your line: my_image = Image.open("imagepath.jpg") Mick On Thu, Oct 4, 2012 at 7:16 PM, Matthew Ngaha wrote: > > im trying to display an image. Ive tried different code from several > tutorials but they seem outdated