QmlDesigner: try to keep zoom combo box smaller

Not sure why it takes so much space, tried different tricks,
nothing was working - so just take the half and hope.

Change-Id: Ib9ea475281b860838391f370c4f1eed98e327903
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
This commit is contained in:
Tim Jenssen
2018-05-03 10:39:10 +02:00
parent 21faaaf2ce
commit a67c192968

View File

@@ -109,6 +109,7 @@ QWidget *ZoomAction::createWidget(QWidget *parent)
connect(this, &ZoomAction::indexChanged, comboBox, &QComboBox::setCurrentIndex);
comboBox->setProperty("hideborder", true);
comboBox->setMaximumWidth(qMax(comboBox->view()->sizeHintForColumn(0) / 2, 16));
return comboBox;
}