I've been digging into why on my laptop the stacked frames in the Input section
appear shifted to the right.
The reason is that the initial loop in fixWidth() sets the minimumwidth
without looking at what the widget is. After some debugging I found out that it
was setting the minimumwidth for the wFrameSR widget.
So I added checks that it only changes it for comboboxes, spinboxes and sliders.
Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
QList<QWidget *> list = parentWidget()->findChildren<QWidget *>();
QList<QWidget *>::iterator it;
for (it = list.begin(); it != list.end(); ++it) {
+ if (!qobject_cast<QComboBox *>(*it) &&
+ !qobject_cast<QSpinBox *>(*it) &&
+ !qobject_cast<QSlider *>(*it))
+ continue;
+
if (((*it)->sizeHint().width()) > m_minWidth) {
m_increment = (int) ceil(((*it)->sizeHint().width() - m_minWidth) / m_pxw);
(*it)->setMinimumWidth(m_minWidth + m_increment * m_pxw); // for stepsize expansion of widgets