wxFindReplaceDialog issues

Robin,

I think wx.FindDialogEvent.GetReplaceText() is broken. When I use this
method in the wxFindReplaceDialog demo, I get _50f41200_p_wxString back
instead of plain text. GetFindText() works fine, though.

Also, I'm looking for some clarification.

I changed the event binding in the demo to use the EVT_FIND (etc) events
rather than EVT_COMMAND_FIND (etc) because the demo was broken (and probably
has been for quite some time). After I did that, I still had breakage, so I
did some fiddling around, source code delving, and here's what I came up
with (extract from the updated demo):

        map = {
            wx.wxEVT_COMMAND_FIND : "FIND",
            wx.wxEVT_COMMAND_FIND_NEXT : "FIND_NEXT",
            wx.wxEVT_COMMAND_FIND_REPLACE : "REPLACE",
            wx.wxEVT_COMMAND_FIND_REPLACE_ALL : "REPLACE_ALL",
            }

Originally this was

        map = {
            wx.EVT_COMMAND_FIND : "FIND",
            wx.EVT_COMMAND_FIND_NEXT : "FIND_NEXT",
            wx.EVT_COMMAND_FIND_REPLACE : "REPLACE",
            wx.EVT_COMMAND_FIND_REPLACE_ALL : "REPLACE_ALL",
            }

This was breaking. The revised version works. But I wonder if that's the way
it should work. Any thoughts?

Jeff Grimmett wrote:

Robin,

I think wx.FindDialogEvent.GetReplaceText() is broken. When I use this
method in the wxFindReplaceDialog demo, I get _50f41200_p_wxString back
instead of plain text. GetFindText() works fine, though.

Thanks. I was missing a typemap definition.

Also, I'm looking for some clarification.

I changed the event binding in the demo to use the EVT_FIND (etc) events
rather than EVT_COMMAND_FIND (etc) because the demo was broken (and probably
has been for quite some time).

Yeah, as I was redoing the swig def's for the FindReplace stuff I realized that I had named the EVT_ functions incorrectly the first time. I guess I didn't also update the demo when I changed it.

···

--
Robin Dunn
Software Craftsman
http://wxPython.org Java give you jitters? Relax with wxPython!