Skip to content

Commit

Permalink
fix: radio setting widget height error
Browse files Browse the repository at this point in the history
Change-Id: I756f22bc6815114905ec5d3593e393e1de247f48
  • Loading branch information
Iceyer committed Oct 26, 2018
1 parent 76c768b commit 6cea6e8
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 1 deletion.
2 changes: 1 addition & 1 deletion src/widgets/dsettingsdialog.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ DSettingsDialog::DSettingsDialog(QWidget *parent) :
d->rightFrame = new QFrame;
d->rightFrame->setObjectName("RightFrame");
d->rightLayout = new QVBoxLayout(d->rightFrame);
d->rightLayout->setContentsMargins(1, 5, 5, 0);
d->rightLayout->setContentsMargins(1, 0, 0, 0);
d->rightLayout->setSpacing(0);

d->content = new Content;
Expand Down
1 change: 1 addition & 0 deletions src/widgets/dsettingswidgetfactory.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -408,6 +408,7 @@ QWidget *createRadioGroupOptionHandle(QObject *opt)
}

rightWidget->setStyleSheet("QGroupBox{border: none;}");
optionWidget->setFixedHeight(24 * items.length() + 8);
return optionWidget;
}

Expand Down
2 changes: 2 additions & 0 deletions src/widgets/private/settings/content.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -196,7 +196,9 @@ void Content::updateSettings(const QByteArray &translateContext, QPointer<DTK_CO
}

auto widget = d->widgetFactory->createWidget(translateContext, option);

if (widget) {
// qDebug() << widget << widget->height();
d->contentLayout->addWidget(widget);
widget->setParent(d->contentFrame);
}
Expand Down

0 comments on commit 6cea6e8

Please sign in to comment.