--------- Original Besked --------
Fra: Mpi <[email protected]>
Til: Phil Thompson <[email protected]>
Emne: Re: [PyQt] QSpinBox and setLineEdit
Dato: 30/01/09 10:49

> 
> --------- Original Besked --------
> Fra: Phil Thompson &lt;[email protected]&gt;
> Til: Mpi &lt;[email protected]&gt;
> Cc: [email protected]
> Emne: Re: [PyQt] QSpinBox and setLineEdit
> Dato: 30/01/09 10:42
> 
> &gt; On Fri, 30 Jan 2009 10:22:57 +0100, Mpi
&amp;lt;[email protected]&amp;gt; wrote:
> &gt; &amp;gt; Hi,
> &gt; &amp;gt; 
> &gt; &amp;gt; You can set a custom line edit on a spinbox using the method
> &gt; setLineEdit().
> &gt; &amp;gt; Suppose I implement a class that inherits from QLineEdit and
> overwirite
> &gt; the
> &gt; &amp;gt; 'setText' method, you'd expect that pressing the arrow
button on the
> &gt; &amp;gt; spinbox
> &gt; &amp;gt; would trigger a call to your custom setText method.
> &gt; 
> &gt; No you wouldn't because setLine() isn't virtual.
> &gt; 
> &gt; Phil
> &gt; 
> 

Well, OK. My problem is that I would like to connect up to the
textChanged(const QString &amp;) signal emitted by the spinbox's lineedit.
This
signal, however, is only emitted when the edit is modified directly, not
when it changes indirectly eg. by pressing the up/down arrows on the
spinbox. Any suggestions for a solution?

Mads
_______________________________________________
PyQt mailing list    [email protected]
http://www.riverbankcomputing.com/mailman/listinfo/pyqt

Reply via email to