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

Unexpected offset of fixed-height top-level window when Windows Taskbar is on top

XMLWordPrintable

    • Windows
    • 33874a942 (dev), 1329e6fac (6.8), 654e2a446 (6.7), 345bec183 (tqtc/lts-6.5), 06fcb3dfe (dev), 5abc6e9cc (6.8)

      Only reproducible when Windows Taskbar is on top of screen. Currently I have only tested Windows 10 since I see no way to move Windows 11 Taskbar around.

      A minimal reproducer:

      int main(int argc, char *argv[])
      {
      QApplication app(argc, argv);
      auto *widget = new QWidget(nullptr);
      QMetaObject::invokeMethod(widget, [widget]{
      widget->setFixedHeight(100);
      }, Qt::QueuedConnection);
      widget->show();
      return app.exec();
      }
      

      First move Taskbar to top, then run the sample, and repeat maximizing and resorting the window. From 2nd maximization, one is going to see a weird offset in y-position as shown in attached gif. And with more repetition goes on, offset grows too. The increment of offset seems to be the height of Taskbar.

        For Gerrit Dashboard: QTBUG-123752
        # Subject Branch Project Status CR V

            axelspoerl Axel Spoerl
            luqiaochen Luqiao Chen
            Votes:
            0 Vote for this issue
            Watchers:
            8 Start watching this issue

              Created:
              Updated:
              Resolved: