[wxPython-users] Drag n' Drop works different for Unicode and
ANSI versions of wxPython
Robin Dunn
robin at alldunn.com
Thu Aug 2 13:01:41 PDT 2007
Ophir Horowitz wrote:
> Hi!
>
>
>
> I use python2.4 with wxPython 2.8.4.0 Unicode and I have encountered a
> weird problem with Drag n' Drop.
>
> I want to drag texts from my application and drop them on a text box
> inside a browser.
>
> When I wrote this code a weird thing happened: it worked only in Firefox
> and not in Internet Explorer.
>
> Even weirder is the fact that when I uninstalled the wxPython Unicode
> version and installed the ANSI version, the Drag n' Drop started to work!
>
>
>
> Of course, this is not a solution, because I need Unicode support in my
> application…
>
In the ansi build wx.TextDataObject uses the CF_TEXT data format. In
the Unicode build it is CF_UNICODE. So basically what you are seeing is
that IE doesn't accept CF_UNICODE formatted objects, which is very silly
considering MIcrosoft's typical stance on this subject...
There was some talk a few years ago about making it possible to have
both CF_TEXT and CF_UNICODE objects available from the
wx.TextDataObject, but I don't think anything was ever done for it.
--
Robin Dunn
Software Craftsman
http://wxPython.org Java give you jitters? Relax with wxPython!
More information about the wxpython-users
mailing list