Problem getting with setGeometry function?



  • If i am displaying two windows one is parent and other as child. While displaying why the child window is taking geometry relative to screen not relative to parent.



  • Top-level windows always have their geometry relative to the desktop. That seems logical to me, as that is the space they move around in. Any parent-child relationship between separate windows is purely for the benefit of the modalness of the child window.

    What do you want to achieve?



  • [quote author="Andre" date="1323755987"]Top-level windows always have their geometry relative to the desktop. That seems logical to me, as that is the space they move around in. Any parent-child relationship between separate windows is purely for the benefit of the modalness of the child window.

    What do you want to achieve?[/quote]

    I want to display a child window in the client area of parent window and the child window should take
    geometry relative to that parent window.



  • Then you are looking for [[doc:QMdiArea]]



  • [quote author="Andre" date="1323756661"]Then you are looking for [[doc:QMdiArea]][/quote]

    Does we can do all the thing with Qmidarea that we can do with normal QMainwindow?



  • You can put a QMdiArea on a QMainWindow as it's central widget.


Log in to reply
 

Looks like your connection to Qt Forum was lost, please wait while we try to reconnect.