Problem with successive attempts to embed external app in QT Widget
-
Hi,
Did you ensure that the layout is empty after removing that embedded application ?
-
Do you have any stretch added ?
-
Interesting fact:
I now noticed that after the second execution of the external application and embedding, and seeing that the embedded app is offset from bottom of layout as mentioned,
If I double click the GUI of the qt app in order to minimize the whole window ("restore down") and then maximizing it, the external app suddenly fits in place.
Is there some sort of refresh method i need to invoke ? -
Does it also happen on resize ?
-
Sorry, I meant: after the second embedding, if you resize the container widget, does it also fix the positioning issue ?
-
Sorry, I meant: after the second embedding, if you resize the container widget, does it also fix the positioning issue ?
@SGaist It seems it did. This is very interesting.
I called the containers resize() method right after the embedClient().
The remote application didn't actually change size to what i specified in resize() and stills fits as intended to it's dedicated layout.
After the second execution of external app again the resize() and embedClient() are called but now the offset has disappeared.
Any conclusion ? -
@walle19 said in Problem with successive attempts to embed external app in QT Widget:
Any conclusion ?
Embedding is tricky ! But also, you are using a version of Qt that is way more than outdated. If locked to Qt 4, you should check with the latest release of that series which is 4.8.7.