Skip to content

Commit

Permalink
Merge pull request #5117 from haikusw/viewport-control-layout-minwidth
Browse files Browse the repository at this point in the history
Viewport-Control widget: Limit width to at least dynamic minimum size of widget. Add tab order back in.  Fixes #5116
  • Loading branch information
t-paul committed May 14, 2024
2 parents ecb06a9 + eaa0985 commit bf01874
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 0 deletions.
5 changes: 5 additions & 0 deletions src/gui/ViewportControl.cc
Original file line number Diff line number Diff line change
Expand Up @@ -106,6 +106,11 @@ void ViewportControl::resizeEvent(QResizeEvent *event)
gridLayout->addWidget(labelFOV, 3, 0, 1, 1);
gridLayout->addWidget(doubleSpinBox_fov, 3, 1, 1, 1);
scrollAreaWidgetContents->layout()->invalidate();
} else {
const auto width = scrollAreaWidgetContents->minimumSizeHint().width();
if (scrollArea->minimumSize().width() != width) {
scrollArea->setMinimumSize(QSize(width,0));
}
}
}
}
Expand Down
13 changes: 13 additions & 0 deletions src/gui/ViewportControl.ui
Original file line number Diff line number Diff line change
Expand Up @@ -331,6 +331,19 @@
</property>
</action>
</widget>
<tabstops>
<tabstop>spinBoxWidth</tabstop>
<tabstop>spinBoxHeight</tabstop>
<tabstop>checkBoxAspecRatioLock</tabstop>
<tabstop>doubleSpinBox_tx</tabstop>
<tabstop>doubleSpinBox_ty</tabstop>
<tabstop>doubleSpinBox_tz</tabstop>
<tabstop>doubleSpinBox_rx</tabstop>
<tabstop>doubleSpinBox_ry</tabstop>
<tabstop>doubleSpinBox_rz</tabstop>
<tabstop>doubleSpinBox_d</tabstop>
<tabstop>doubleSpinBox_fov</tabstop>
</tabstops>
<resources/>
<connections/>
</ui>

0 comments on commit bf01874

Please sign in to comment.