Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. Problem getting with setGeometry function?
Forum Updated to NodeBB v4.3 + New Features

Problem getting with setGeometry function?

Scheduled Pinned Locked Moved General and Desktop
6 Posts 2 Posters 3.1k Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • P Offline
    P Offline
    pratik041
    wrote on last edited by
    #1

    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.

    Pratik Agrawal

    1 Reply Last reply
    0
    • A Offline
      A Offline
      andre
      wrote on last edited by
      #2

      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?

      1 Reply Last reply
      0
      • P Offline
        P Offline
        pratik041
        wrote on last edited by
        #3

        [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.

        Pratik Agrawal

        1 Reply Last reply
        0
        • A Offline
          A Offline
          andre
          wrote on last edited by
          #4

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

          1 Reply Last reply
          0
          • P Offline
            P Offline
            pratik041
            wrote on last edited by
            #5

            [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?

            Pratik Agrawal

            1 Reply Last reply
            0
            • A Offline
              A Offline
              andre
              wrote on last edited by
              #6

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

              1 Reply Last reply
              0

              • Login

              • Login or register to search.
              • First post
                Last post
              0
              • Categories
              • Recent
              • Tags
              • Popular
              • Users
              • Groups
              • Search
              • Get Qt Extensions
              • Unsolved