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

Windows: resizing a window with setGeometry() doesn't move and resize at once

    XMLWordPrintable

Details

    • Bug
    • Resolution: Duplicate
    • Not Evaluated
    • None
    • 5.2.1
    • GUI: Window management
    • None

    Description

      When trying to add roll my own window resize behavior for a Frameless widget I found that on Windows when I attempt to resize the window with setGeometry() it appears to do resize and move in separate steps. This creates a very unpleasant effect where the window shakes as you resize it. Also contained widgets also don't resize until what appears to be after the containing widget's resize is done. This shows up as the inner widget overlapping the outer widget's border when resizing to the left or down.

      I've attached an example that demonstrates the issue.

      • Build and run the sample on Windows.
      • Click anywhere inside the window and drag to the left.
      • Watch the right edge and note how it shakes left and right.
      • Now drag to the right.
      • Notice how the red inner rectangle overlaps the blue border.

      On OS X this behaves as expected and the right edge stays stationary and the red square never overlaps the blue border. This is what I expect to happen in Windows.

      Attachments

        1. main.cpp
          1 kB
        2. qtbug39618.zip
          2 kB

        Issue Links

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

          Activity

            People

              Unassigned Unassigned
              nom nom
              Votes:
              1 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Gerrit Reviews

                  There are no open Gerrit changes