Qt: Set a minimum width for our stream spinboxes.

Set a minimum width for the stream and substream number spinboxes in the
"Follow" and "TCP Stream Graphs" dialogs. This provides a larger click
target and should make editing easier.
Fixes #18265.
pespin/osmux-wip
Gerald Combs 2022-09-28 12:55:14 -07:00
parent e0c563c71e
commit 91bb68c86a
2 changed files with 5 additions and 0 deletions

View File

@ -89,6 +89,9 @@ FollowStreamDialog::FollowStreamDialog(QWidget &parent, CaptureFile &cf, follow_
ui->setupUi(this);
loadGeometry(parent.width() * 2 / 3, parent.height());
ui->streamNumberSpinBox->setStyleSheet("QSpinBox { min-width: 2em; }");
ui->subStreamNumberSpinBox->setStyleSheet("QSpinBox { min-width: 2em; }");
switch(type)
{
case FOLLOW_TCP:

View File

@ -131,6 +131,8 @@ TCPStreamDialog::TCPStreamDialog(QWidget *parent, capture_file *cf, tcp_graph_ty
if (parent) loadGeometry(parent->width() * 2 / 3, parent->height() * 4 / 5);
setAttribute(Qt::WA_DeleteOnClose, true);
ui->streamNumberSpinBox->setStyleSheet("QSpinBox { min-width: 2em; }");
guint32 th_stream = select_tcpip_session(cap_file_);
if (th_stream == G_MAXUINT32) {
done(QDialog::Rejected);