look into XRCed, is part of the standard wxPython distribution (tools dir) then use XmlResource (look in the demo for an example)
the key will be to keep a copy of the XML string and pass that when you D&D then recreate on the other side
XML is no big deal... the code will load fast enough don't worry about that.
Just give it a try...
Peter.
路路路
On Wed, 09 Nov 2005 18:26:15 +0200, <andrea.gavana@agip.it> wrote:
Hello Alex, Peter & NG,
you could describe the button with all its properties as a text and
use the marshaled text as your custom data object.Thanks for your suggestions. However, this raises another question: how can
I describe something complex like a panel in which I put a bounch of
controls in a text string? This seems very complicated to me, or even
impossible... I was thinking about XML as Peter suggested, but when you
have a lot of controls this may become quite difficult. Moreover, if I give
a panel with a lot of controls inside it, does XML create code
automagically? Will it be slow to reload the code from XML? Sorry for the
stupid questions, I am not really familiar with XML...Thanks a lot, as usual, for your useful suggestions.