Help on Tkinter installation

Cameron Laird claird at lairds.com
Wed Mar 17 19:04:53 EST 2004


In article <slrnc5hli1.lpk.slimick at venango.upb.pitt.edu>,
John Slimick  <slimick at pitt.edu> wrote:
>I want to do a little Tkinter in my 1 credit 
>python practicum, but I am having problems
>getting everything installed correctly.
>A sample of the problem is below:
>
>
>------------------- The python source, test.py ------------------
>from graphics import *
>
>def main():
>    win = GraphWin("My Circle", 100, 100)
>    c = Circle(Point(50,50), 10)
>    c.draw(win)
>
>main()
>
>----------- result of $python test.py --------------------------
>
>Traceback (most recent call last):
>  File "test.py", line 1, in ?
>    from graphics import *
>  File "/home/slimick/cs198/graphics.py", line 85, in ?
>    import Tkinter
>  File "/usr/local/lib/python2.3/lib-tk/Tkinter.py", line 38, in ?
>    import _tkinter # If this fails your Python may not be configured for Tk
>  ImportError: No module named _tkinter
>
>------------result of $locate _tkinter ------------------------------
>
>/usr/src/redhat/SOURCES/Python-2.3.2/Mac/Build/_dummy_tkinter.mcp
>/usr/src/redhat/SOURCES/Python-2.3.2/Mac/Build/_dummy_tkinter.mcp.exp
>/usr/src/redhat/SOURCES/Python-2.3.2/Mac/Modules/_dummy_tkinter.c
>/usr/src/redhat/SOURCES/Python-2.3.2/Modules/_tkinter.c
>/usr/src/redhat/SOURCES/Python-2.3.2/PC/os2vacpp/_tkinter.def
>/usr/src/redhat/SOURCES/Python-2.3.2/PCbuild/_tkinter.dsp
			.
			.
			.
More pertinent than your source code, which, to the best of my
understanding, has multiple difficulties, is information about
the host on which you're attempting to run it.  I'm guessing 
it's a RedHat Linux ...  I'd think easiest for you would be to
rely on ActivePython <URL:
http://tkinter.unpythonic.net/wiki/How_20to_20install_20Tkinter >.

I'm curious about how you decided to start with the program you've
exhibited above.
-- 

Cameron Laird <claird at phaseit.net>
Business:  http://www.Phaseit.net



More information about the Python-list mailing list