473,397 Members | 1,969 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,397 software developers and data experts.

New to Tkinter...

Good Morning.

I am new to Tkinter. I have been testing the installation of Tkinter
through the python web site. The first two test steps give no errors,
'import _tkinter' and 'import Tkinter'. However, the third step,
'Tkinter._test', gives the error:
<function _test at 0xb7ec8df4>

Any suggestions?

pete

--
Peter G. Carswell
The Ohio Supercomputer Center
pe**@osc.edu
work: 614.292.1091
fax: 614.292.XXXX
"DOC NOTE, I DISSENT. A FAST NEVER PREVENTS A FATNESS. I DIET ON COD."
-Peter Hilton

Jul 19 '05 #1
4 2080
On Tue, 19 Apr 2005 09:35:03 -0400, Peter G Carswell <pe**@osc.edu> wrote:
Good Morning.

I am new to Tkinter. I have been testing the installation of Tkinter
through the python web site. The first two test steps give no errors,
'import _tkinter' and 'import Tkinter'. However, the third step,
'Tkinter._test', gives the error:
<function _test at 0xb7ec8df4>


This is not an error. It's just the value of the _test function in the Tkinter module. You don't give the URL where you found the installation/test instructions, but you probably want:

Tkinter._test()

which *calls* the function. Tkinter._test just returns its value (functions are first class objects in Python...)

HTH
--
python -c 'print "".join([chr(154 - ord(c)) for c in "U(17zX(%,5.z^5(17l8(%,5.Z*(93-965$l7+-"])'
Jul 19 '05 #2
Eric Brunel wrote:
On Tue, 19 Apr 2005 09:35:03 -0400, Peter G Carswell <pe**@osc.edu>
wrote:
Good Morning.

I am new to Tkinter. I have been testing the installation of Tkinter
through the python web site. The first two test steps give no errors,
'import _tkinter' and 'import Tkinter'. However, the third step,
'Tkinter._test', gives the error:
<function _test at 0xb7ec8df4>

This is not an error. It's just the value of the _test function in the
Tkinter module. You don't give the URL where you found the
installation/test instructions, but you probably want:

Tkinter._test()

which *calls* the function. Tkinter._test just returns its value
(functions are first class objects in Python...)

HTH


Thanks, I realized my beginners' error just after I emailed the
newgroup. I am sure this won't be my last question.

pete
--
Peter G. Carswell
The Ohio Supercomputer Center
pe**@osc.edu
work: 614.292.1091
fax: 614.292.XXXX
"DOC NOTE, I DISSENT. A FAST NEVER PREVENTS A FATNESS. I DIET ON COD."
-Peter Hilton

Jul 19 '05 #3
Eric Brunel wrote:
This is not an error. It's just the value of the _test function in the
Tkinter module. You don't give the URL where you found the
installation/test instructions, but you probably want:

Tkinter._test()

which *calls* the function. Tkinter._test just returns its value
(functions are first class objects in Python...)


I did get a positive result on my linux desktop. However, on my laptop
Fedora Core 1, the Tk window shell popped up with no buttons:

Python 2.2.3 (#1, Oct 15 2003, 23:33:35)
[GCC 3.3.1 20030930 (Red Hat Linux 3.3.1-6)] on linux2
Type "help", "copyright", "credits" or "license" for more information.
import _tkinter
import Tkinter
Tkinter._test() Traceback (most recent call last):
File "<stdin>", line 1, in ?
File "/usr/lib/python2.2/lib-tk/Tkinter.py", line 3118, in _test
label = Label(root, text=text)
File "/usr/lib/python2.2/lib-tk/Tkinter.py", line 2285, in __init__
Widget.__init__(self, master, 'label', cnf, kw)
File "/usr/lib/python2.2/lib-tk/Tkinter.py", line 1780, in __init__
self.tk.call(
SystemError: Py_UNICODE and Tcl_UniChar differ in size


pete

--
Peter G. Carswell
The Ohio Supercomputer Center
pe**@osc.edu
work: 614.292.1091
fax: 614.292.XXXX
"DOC NOTE, I DISSENT. A FAST NEVER PREVENTS A FATNESS. I DIET ON COD."
-Peter Hilton

Jul 19 '05 #4
hue
Hello

Jul 19 '05 #5

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
by: Josh | last post by:
Caution, newbie approaching... I'm trying to come up with a very simple Tkinter test application that consists of a window with a drop-down menu bar at the top and a grid of colored rectangles...
3
by: srijit | last post by:
Hello, Any idea - why the following code crashes on my Win 98 machine with Python 2.3? Everytime I run this code, I have to reboot my machine. I also have Win32all-157 installed. from Tkinter...
1
by: syed_saqib_ali | last post by:
Please take a look at and run the code snippet shown below. It creates a canvas with vertical & Horizontal scroll-bars. If you shrink the window to smaller than the area of the canvas, the...
0
by: syed_saqib_ali | last post by:
Below is a simple code snippet showing a Tkinter Window bearing a canvas and 2 connected scrollbars (Vertical & Horizontal). Works fine. When you shrink/resize the window the scrollbars adjust...
1
by: Michael Yanowitz | last post by:
Hello: Below I have included a stripped down version of the GUI I am working on. It contains 2 dialog boxes - one main and one settings. It has the following problems, probably all related, that...
3
by: dwelch91 | last post by:
I'm trying unsuccessfully to do something in Tk that I though would be easy. After Googling this all day, I think I need some help. I am admittedly very novice with Tk (I started with it...
1
by: yvesd | last post by:
hello i want to intercept tkinter python system events like wm_delete_window and if possible for any window, but the newest code I've produced give me an error : Traceback (most recent call...
8
by: karthikbalaguru | last post by:
Hi, One of my python program needs tkinter to be installed to run successfully. I am using Redhat 9.0 and hence tried installing by copying the tkinter-2.2.2-36.i386.rpm alone from the CD 3 to...
3
by: joshdw4 | last post by:
I hate to do this, but I've thoroughly exhausted google search. Yes, it's that pesky root window and I have tried withdraw to no avail. I'm assuming this is because of the methods I'm using. I...
3
by: J-Burns | last post by:
Hello. Im a bit new to using Tkinter and im not a real pro in programming itself... :P. Need some help here. Problem 1: How do I make something appear on 2 separate windows using Tkinter? By...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.