Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl-Sensitive Sunglasses
 
PerlMonks  

No wxTextCompleterSimple class?

by einhverfr (Friar)
on Nov 15, 2013 at 09:51 UTC ( [id://1062724]=perlquestion: print w/replies, xml ) Need Help??

einhverfr has asked for the wisdom of the Perl Monks concerning the following question:

Fellow monks

Still working on the wxperl point of sale application and trying to add autocomplete to some text fields.

The wxwidget documentation mentions a wxTextCompleter and a wxTextCompleterSimple class. I have tried to instantiate these and I keep getting errors that the class is empty. Am I missing something? Is there a workable alternative for wxWidget-based applications?

The lines in my code are:

package Package::Name; # not the real name but... use Wx; use base 'Wx::wxTextCompleterSimple'; # these lines copied verbatim
My error is: Base class package "Wx::wxTextCompleterSimple" is empty.

Replies are listed 'Best First'.
Re: No wxTextCompleterSimple class? ( nope )
by Anonymous Monk on Nov 15, 2013 at 10:11 UTC

      Thanks, the lines were copied from my source code.

      What I was trying to find is where I was going wrong. It looks like my system has wxwidgets 2.8 which is the main source of the problem. Apparently it is a good idea to follow the same version of docs and code...

      I ended up switching for now from textboxes to comboboxes to try to implement my own autocomplete that way. However if I setfocus to the combobox, it selects the text which makes it very hard to change the combinations in it. Do you know of a good way to do autocomplete with wxPerl and wxwidgets 2.8?

      Edit: Never mind. I found that the issue was that the best thing to do was to avoid setting the value, and instead process the items on the list.

Re: No wxTextCompleterSimple class?
by stefbv (Curate) on Nov 15, 2013 at 09:59 UTC

    What wxWidgets version do you use?

    Conform to the docs is only available since 2.9.2.

    Update:It looks like Wx Version: 0,9921 wxWidgets 2.9.4 doesn't know about it...

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: perlquestion [id://1062724]
Approved by GrandFather
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others perusing the Monastery: (7)
As of 2024-04-25 15:04 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found