Details
-
Bug
-
Resolution: Invalid
-
Not Evaluated
-
None
-
5.3.1
-
None
Description
I've been trying to create a groupBox widget with a scrollArea using Qt Creator. Looking at the resultant generated ui_settings.h file (attached) I noticed that the scrollArea::setWidget is being applied to QWidget *scrollAreaWidgetContents
scrollArea->setWidget(scrollAreaWidgetContents);
whereas the items in the groupBox were actually being added to QWidget *layoutWidget2, created as
layoutWidget2 = new QWidget(scrollAreaWidgetContents);
If I modify the uic-generated ui_settings.h file to assign the scrollArea::setWidget to this layoutWidget2 instead of scrollAreaWidgetContents, then the scrollbars appear
scrollArea->setWidget(layoutWidget2);
I then looked at the ui file (settings.ui, attached) and noticed there was no layoutWidget2. So I did a make clean - cleaned everything out and did a manual uic on the ui file and saw the following warnings:
settings.ui: Warning: The name 'layoutWidget' (QWidget) is already in use, defaulting to 'layoutWidget1'.
settings.ui: Warning: The name 'layoutWidget' (QWidget) is already in use, defaulting to 'layoutWidget2'
I was searching through through the bug reports using various keywords before writing up a new one. The closest one I found was QTCREATORBUG-7044 so I added notes there but decided to write up a new one.