[Patches] [ python-Patches-518625 ] Return objects in Tkinter

noreply@sourceforge.net noreply@sourceforge.net
Fri, 22 Nov 2002 05:25:30 -0800


Patches item #518625, was opened at 2002-02-16 19:36
You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=305470&aid=518625&group_id=5470

Category: Tkinter
Group: None
Status: Open
Resolution: None
Priority: 5
Submitted By: Martin v. L÷wis (loewis)
Assigned to: Nobody/Anonymous (nobody)
Summary: Return objects in Tkinter

Initial Comment:
This patch uses the Tcl object API to convert return
values to Python objects. For boolean, bytearray,
double, int, list, and string objects, the equivalent
Python objects are constructed (Unicode for Tcl
string). For untyped objects, strings are returned. For
all other objects, a Python wrapper object is returned
which supports a tp_str conversion.

----------------------------------------------------------------------

>Comment By: Guido van Rossum (gvanrossum)
Date: 2002-11-22 08:25

Message:
Logged In: YES 
user_id=6380

I can't answer that question, since I don't know what's out
in the field. If you don't get response from python-dev,
let's try this and see how it fares during the alpha tests.

----------------------------------------------------------------------

Comment By: Martin v. L÷wis (loewis)
Date: 2002-11-22 08:20

Message:
Logged In: YES 
user_id=21627

I was originally asked to put this on SF for review because
the potential backwards incompatibility in return types.
IDLE seems to work fine with this change, so I expect
incompatibility to come up rarely.

Can I commit this as-is, with the suggestion that
applications that break with this can do

import Tkinter
Tkinter.want_objects = 0

----------------------------------------------------------------------

Comment By: Guido van Rossum (gvanrossum)
Date: 2002-11-22 07:10

Message:
Logged In: YES 
user_id=6380

Looks OK in theory.

----------------------------------------------------------------------

You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=305470&aid=518625&group_id=5470