Uploaded image for project: 'Qt'
  1. Qt
  2. QTBUG-30636

Regression: QWidget::restoreGeometry does not work correctly after maximized

    XMLWordPrintable

Details

    • Bug
    • Resolution: Done
    • P2: Important
    • 5.3.0
    • 4.8.4, 5.0.1
    • None
    • Windows 7, Linux ubuntu
    • qtbase I3819ebaf55b4e7d2f7eef1affe6c20712ba45d7c (5.3, QPLatformWindow::normalGeometry), d38ae7ea322bedb16045d0dc4a71498fadfb2dd9 (Qt 4 ,4.8.6)

    Description

      QWidget::restoreGeometry() is not restoring the correct size for a QMainWindow if the application was closed after maximized. The attached example shows the issue with the following steps:

      1. Start the application
      2. Resize the application
      3. Maximize the window
      4. Close the application (saves geometry)
      5. Start the application again
      6. Restore down the window

      Result: the window is restored to the default size.

      Expected results: the window is restored to the size it was resized into in step 2.

      This was working correctly with Qt 4.7.4.

      Regression due to SHA1 54865d47cfd859a0e84ba8e1bbff3b56c93d4e0d.

      (Related to https://bugreports.qt-project.org/browse/QTBUG-21371)

      Attachments

        1. qtbug30636.zip
          3 kB
        2. test_bug.zip
          1 kB

        Issue Links

          No reviews matched the request. Check your Options in the drop-down menu of this sections header.

          Activity

            People

              kleint Friedemann Kleint
              qtcomsupport Qt Support
              Votes:
              3 Vote for this issue
              Watchers:
              9 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Gerrit Reviews

                  There are no open Gerrit changes