forked from qt-creator/qt-creator
Even more Qt6 porting
Task-number: QTCREATORBUG-24098 Change-Id: Ib6ef0e521483153c9716c9a1870072e836d6b026 Reviewed-by: Eike Ziller <eike.ziller@qt.io>
This commit is contained in:
@@ -461,11 +461,14 @@ QWidget *SpacerField::createWidget(const QString &displayName, JsonFieldPage *pa
|
||||
{
|
||||
Q_UNUSED(displayName)
|
||||
Q_UNUSED(page)
|
||||
int size = QApplication::style()->pixelMetric(QStyle::PM_DefaultLayoutSpacing) * m_factor;
|
||||
int hspace = QApplication::style()->pixelMetric(QStyle::PM_LayoutHorizontalSpacing);
|
||||
int vspace = QApplication::style()->pixelMetric(QStyle::PM_LayoutVerticalSpacing);
|
||||
int hsize = hspace * m_factor;
|
||||
int vsize = vspace * m_factor;
|
||||
|
||||
auto w = new QWidget();
|
||||
w->setMinimumSize(size, size);
|
||||
w->setMaximumSize(size, size);
|
||||
w->setMinimumSize(hsize, vsize);
|
||||
w->setMaximumSize(hsize, vsize);
|
||||
w->setSizePolicy(QSizePolicy::Fixed, QSizePolicy::Fixed);
|
||||
return w;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user