[Interest] Place a QWidget below a button (and follow it!)

william.crocker at analog.com william.crocker at analog.com
Thu Jun 13 19:37:49 CEST 2013

> In details, I have a widget that will display a floating window when the
> user clicks on a QToolButton. This floating widget must be placed below
> the button that summoned its soul, and if the main window moves, the
> floating window must be positioned in the same place.

Reimplement the moveEvent of the main window
(which has the tool button as a child.)
In it, reevaluate the position of the child
tool button (to be tracked) and move the
floating window as required.

Converting widget positions in and out of the
global coordinate system will come in handy.


More information about the Interest mailing list