Possible Duplicate:
ImportError when importing Tkinter in Python
I have a Mac with Mountain Lion installed on it. I want to dev for Python on it, so I grabbed a Python 3.3 release candidate and started to work with it. However, I was trying to start working with Tkinter graphics, and when I tried this line:
from Tkinter import *
Eclipse (and IDLE) gave me this nasty error
Traceback (most recent call last):
File "/Users/venkatsmoorthy/Documents/workspace/Python/python/tkinterGUI/tkinter_1.py" line 7, in <module>
from Tkinter import *
ImportError: No module named 'Tkinter'
I don't wan't to downgrade. I am willing to though, but only to 3.2.3. Please don't make me do it.
I did google around, and figured out that OSX has some problem with Tkinter. I tried a few solutions, but no dice. Please answer with your own instructions for how to get tkinter working on python 3.3/3.2.
Tkinter is a graphical user interface (GUI) module for Python, you can make desktop apps with Python. You can make windows, buttons, show text and images amongst other things. Tk and Tkinter apps can run on most Unix platforms. This also works on Windows and Mac OS X.
The only difference between Tkinter and tkinter is that Tkinter was initially used with Python 2 and tkinter is used for working with Python 3 or later versions.
Tkinter actually comes along when we install Python. While installing Python, we need to check the td/tk and IDLE checkbox. This will install the tkinter and we need not install it separately. However, if we missed installing Tkinter while installing Python, we can do it later using the pip command.
Python 3 calls it tkinter
not Tkinter
.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With