Hi all,

I'm working in my first project with wxHaskell.  My project includes an
editor, so I wanted to add find&replace functionality to it but then I
stepped into what I think is a little bug.
I think you'll see the problem clearly with an example (and it will be
easier for me than explaining it in english :P):
Let's say you've got the following code


>         *s* <- *findReplaceDataCreateDefault*
>         *findReplaceDataSetFindString* *s* "find"
>         *findReplaceDataSetReplaceString* *s* "replace"
>         *r* <- *findReplaceDataGetReplaceString* *s*
>

You expect that, when executed, the value of r will be "replace", but it's
not.  It's "find" instead.
Googleing a bit, I've found that this is a known bug in wxEiffel:
http://www.mombu.com/programming/eiffel/t-problems-getting-a-wx-find-replace-data-1408529.html
Then, I've checked the source code for wxHaskell (
http://darcs.haskell.org/wxhaskell/wxc/src/eljfindrepldlg.cpp) and found
this:

EWXWEXPORT(wxString*,*wxFindReplaceData_GetReplaceString*)(void* _obj)
> {
>     wxString *result = new wxString();
>     *result = ((wxFindReplaceData*)_obj)->*GetFindString*();
>     return result;
> }
>
I think that explains it.  Then I decided to write this mail to let
you know about it, so maybe it can be fixed in the next wxHaskell
release :)


Cheers!!



Joan Crawford<http://www.brainyquote.com/quotes/authors/j/joan_crawford.html>
- "I, Joan Crawford, I believe in the dollar. Everything I earn, I
spend."
------------------------------------------------------------------------------
Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day 
trial. Simplify your report design, integration and deployment - and focus on 
what you do best, core application coding. Discover what's new with 
Crystal Reports now.  http://p.sf.net/sfu/bobj-july
_______________________________________________
wxhaskell-users mailing list
wxhaskell-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wxhaskell-users

Reply via email to