[Tutor] Adding attributes to imported class
klappnase at freenet.de
Thu Jul 7 12:27:03 CEST 2005
On Thu, 07 Jul 2005 11:03:00 +1200 (NZST)
jfouhy at paradise.net.nz wrote:
> Quoting Michael Lange <klappnase at freenet.de>:
> > I'm trying to write a python wrapper for the tkDnD Tk extension to add
> > drag and drop support
> Hi Michael,
> Just a side issue --- tkDnD seems to be broken in python 2.4: see bug 1164742,
thanks for the pointer , but of course I did not mean the python module but the Tk extension library
( http://sourceforge.net/projects/tkdnd ), which adds "real" dnd support to Tk.
As far as I have tested (not very much however) it seems to work now, but I'm still not sure if the on-the-fly adding of attributes
to classes of an imported module is proper programming style or "do-it-yourself lobotomy" .
It is the first time for me to try wrapping a Tk extension for python, so I am not sure of the way to go.
Anyway, it's a cool new feature for Tkinter, so I thought I should share it with the community;
anyone who is interested can find it at http://www.8ung.at/klappnase/TkinterDnD/TkinterDnD.html .
Any feedback is much appreciated.
More information about the Tutor