[Qt-interest] QValidator::validate() and QLineEdit ... when is it called?
Robert Hairgrove
evorgriahr at hispeed.ch
Sat Feb 5 12:30:47 CET 2011
On Fri, 2011-02-04 at 17:44 -0600, Ellen Kestrel wrote:
> IIRC, QValidator is mainly for requiring input to match certain
> regexps, not for what you're trying to do. It might be possible to
> get it to do that, but I don't know how you would do it, and it seems
> like if you tried it you would just be working at odds with the Qt API
> anyway. If you want something to happen with the QLineEdit's text
> whenever the editingFinished () signal is emitted, why not just make
> your own slot to do whatever needs doing and connect it to the
> editingFinished () signal? That way you won't even need to write your
> own subclass.
>
> EK
Thank you very much. This is what I have done, and it works as it
should.
More information about the Qt-interest-old
mailing list