[PyKDE] Cannot connect QSplitter signal

Phil Thompson phil at riverbankcomputing.co.uk
Wed Jul 2 21:42:00 BST 2003


On Wednesday 02 July 2003 8:29 pm, Toru Furukawa wrote:
> On Tue, 1 Jul 2003 19:31:08 +0100
>
> Phil Thompson <phil at riverbankcomputing.co.uk> wrote:
> > > How can I detect mouse events on the splitter widget?
>
> ...
>
> > > class MySplitter(QSplitter):
> > >     def event(self, e):
> > >         print "#", e
> > >         return QSplitter.event(self, e)
> > >     def mouseDoubleClickEvent(self, e):
> > >         print "*", e
> > >         QSplitter.mouseDoubleClickEvent(self, e)
>
> ...
>
> > Just to clarify, the double-click is received by the splitter if you
> > click on either of the QWidgets - not if you click on the "long
> > rectangular stuff" between them.
>
> Oh, that clarifies my problem.  My question becomes how to recieve
> double-click events on a separator, or how to get the widget instance
> which represents a separator.   Is there any way to do that?

Looking at the source for QSplitter - I don't think so.

Phil




More information about the PyQt mailing list