In my Qt application, I have couple of QtWidgets which are floating. I want to know when QtWidget is dragged to another screen So that I can resize content within according to new screen DPI.
In my Qt application, I have couple of QtWidgets which are floating. I want to know when QtWidget is dragged to another screen So that I can resize content within according to new screen DPI.
Connect the primaryScreenChanged signal from your QGuiApplication to slots in your widgets.
Edited to add: On reflection, this probably doesn't do what you want -- it signals when the application changes screen, not the widget.