[Interest] Glueing widgets together
tony at rightsoft.com.au
Fri Jun 28 10:54:42 CEST 2013
I have a master dialog with a slave dialog attached to one border. This was
done using eventFilter in the slave to listen to the master Move and Resize
events - not MouseMove. It's only 10 lines of code, works well and there is
no jerkiness. It put the code in the slave, since it can be attached to
many different dialogs in my app.
The same code should work for peer dialogs - but you must be careful to
prevent recursion by settings flags in the other dialog before moving it so
it doesn't try to move the first one. The recursion could cause the delays
and high CPU usage.
Can you show the code that isn't working?
From: interest-bounces+tony=rightsoft.com.au at qt-project.org
[mailto:interest-bounces+tony=rightsoft.com.au at qt-project.org] On Behalf Of
Sent: Friday, 28 June 2013 5:18 PM
To: interest at qt-project.org
Subject: [Interest] Glueing widgets together
I've posted some time ago a question about moving widgets simultaneously.
However, the proposed solutions were unsatisfactory.
That is probably because I've expressed my needs in a non useful way. So
here it goes.
I need to "glue together" two widgets, so that when one moves, the other
They should appear glued even when dragging around, fast and slow. Like if
the "follower" is simply painted over the moving widget.
The proposed solutions involve getting the mouse move events dealt with.
This resulted in a visible delay, and that isn't what I want: I don't want
to see the window moving with the follower staying still, and after few
instants, the follower (disappearing from where it was) painted in the right
Is there any way I can achieve this visual effect?
Thanks & Cheers!
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the Interest