mirror of
https://github.com/Chatterino/chatterino2.git
synced 2024-11-21 22:24:07 +01:00
fixed spacing
This commit is contained in:
parent
eaaa52260e
commit
0ada2e51c6
1 changed files with 10 additions and 10 deletions
|
@ -49,9 +49,10 @@ void SettingsDialog::initUi()
|
|||
LayoutCreator<SettingsDialog> layoutCreator(this);
|
||||
|
||||
// tab pages
|
||||
layoutCreator.setLayoutType<QHBoxLayout>()
|
||||
.withoutSpacing()
|
||||
.emplace<QWidget>()
|
||||
auto outerBox = layoutCreator.setLayoutType<QHBoxLayout>();
|
||||
outerBox->setSpacing(12);
|
||||
|
||||
outerBox.emplace<QWidget>()
|
||||
.assign(&this->ui_.tabContainerContainer)
|
||||
.emplace<QVBoxLayout>()
|
||||
.withoutMargin()
|
||||
|
@ -59,8 +60,6 @@ void SettingsDialog::initUi()
|
|||
|
||||
this->ui_.tabContainerContainer->layout()->setContentsMargins(8, 8, 0, 39);
|
||||
|
||||
this->layout()->setSpacing(0);
|
||||
|
||||
// right side layout
|
||||
auto right =
|
||||
layoutCreator.emplace<QVBoxLayout>().withoutMargin().withoutSpacing();
|
||||
|
@ -125,11 +124,16 @@ void SettingsDialog::initUi()
|
|||
auto searchButton = header.emplace<Button>();
|
||||
searchButton->setPixmap(getApp()->resources->buttons.search);
|
||||
searchButton->setScaleIndependantSize(30, 30);
|
||||
QObject::connect(
|
||||
searchButton.getElement(), &Button::clicked, this,
|
||||
[]() { QDesktopServices::openUrl({"https://google.com"}); });
|
||||
|
||||
right.emplace<QStackedLayout>()
|
||||
.assign(&this->ui_.pageStack)
|
||||
.withoutMargin();
|
||||
|
||||
right->addSpacing(12);
|
||||
|
||||
auto buttons = right.emplace<QDialogButtonBox>(Qt::Horizontal);
|
||||
{
|
||||
this->ui_.okButton =
|
||||
|
@ -161,8 +165,6 @@ void SettingsDialog::addTabs()
|
|||
this->ui_.tabContainer->setMargin(0);
|
||||
this->ui_.tabContainer->setSpacing(0);
|
||||
|
||||
this->ui_.tabContainer->addSpacing(16);
|
||||
|
||||
this->addTab(new GeneralPage);
|
||||
|
||||
this->ui_.tabContainer->addSpacing(16);
|
||||
|
@ -216,9 +218,7 @@ void SettingsDialog::selectTab(SettingsDialogTab *tab, bool byUser)
|
|||
|
||||
tab->setSelected(true);
|
||||
tab->setStyleSheet("background: #222; color: #4FC3F7;"
|
||||
"border-left: 1px solid #444;"
|
||||
"border-top: 1px solid #444;"
|
||||
"border-bottom: 1px solid #444;");
|
||||
"border: 1px solid #444;");
|
||||
this->selectedTab_ = tab;
|
||||
if (byUser)
|
||||
{
|
||||
|
|
Loading…
Reference in a new issue