[Interest] Problems with QDockWidgets in Qt5.6.1 and Qt5.7
Chris Gripeos
chris.gripeos at harmonixmusic.com
Thu Jun 23 18:25:12 CEST 2016
Hello,
I'm seeing some new and strange behaviour after upgrading our app from Qt5.6.0 to Qt5.6.1 and even Qt5.7.0 (5.6.1 and 5.7 have the same exact behaviour).
I have a QDockWidget with:
setAllowedAreas(Qt::AllDockWidgetAreas)
And I have a QMainWindow with:
setDockOptions(QMainWindow::AllowTabbedDocks | QMainWindow::AllowNestedDocks);
setTabPosition(Qt::AllDockWidgetAreas, QTabWidget::North);
The QMainWindow is populated with a Central Widget that has a minimum width, but still has plenty of room to add the QDockWidget to the left or right areas.
The QDockWidget has a minimum width and height, but still has plenty of room to be docked in the QMainWindow.
Now, when I drag the QDockWidget in the QMainWindow, Qt highlights the areas on the left, top, bottom, and right as I drag the QDockWidget around. This tells me that if the dock areas are highlighted I should be allowed to drop the QDockWidget on them.
The problem is that as soon as i drop the QDockWidget in those areas, the Widget only gets docked on the Right Area.
No matter which area I try to drop it on, it always ends up on the Right.
In Qt5.6.0 and earlier (we were on Qt4.8 before that):
- Qt would *only* highlight areas where a Widget was allowed to be docked. Qt5.6.1 seems to highlight all areas, even when not allowed (no-fit).
- Docking was possible on the highlighted areas without the QDockWidget always getting docked on the Right.
Has anybody else experience such a problem with Qt5.6.1 or Qt5.7.0?
Does anybody know what it might be that we're doing wrong?
Thanks in advance for any help with this problem!
- Chris
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.qt-project.org/pipermail/interest/attachments/20160623/9832df0b/attachment.html>
More information about the Interest
mailing list