From b550c8e181d6f2719b358bf3dba7cd8f6c7596c7 Mon Sep 17 00:00:00 2001 From: Sheila Aman Date: Sun, 23 May 2021 10:40:56 -0500 Subject: [PATCH] layout improvements --- src/exdeath.cc | 29 ++++++++++++++++------------- src/exdeath.hh | 8 +++++--- 2 files changed, 21 insertions(+), 16 deletions(-) diff --git a/src/exdeath.cc b/src/exdeath.cc index e4cffb4..6be16d8 100644 --- a/src/exdeath.cc +++ b/src/exdeath.cc @@ -34,18 +34,20 @@ Exdeath::Exdeath(QWidget *parent) : QWidget(parent) { error = new QErrorMessage(); filename = nullptr; - layContainer = new QVBoxLayout(this); + layApp = new QVBoxLayout(this); + layColumns = new QVBoxLayout(this); + layApp->addLayout(layColumns); layMain = new QGridLayout(this); layMode = new QVBoxLayout(this); - layDemi = new QVBoxLayout(this); + layInnates = new QVBoxLayout(this); grpMain = new QGroupBox("Main"); grpMain->setLayout(layMain); - grpDemi = new QGroupBox("Innate abilities"); - grpDemi->setLayout(layDemi); - layContainer->addWidget(grpMain); - layContainer->addWidget(grpDemi); + grpInnates = new QGroupBox("Innate abilities"); + grpInnates->setLayout(layInnates); + layColumns->addWidget(grpMain); + layColumns->addWidget(grpInnates); // Main options txtROM = new QLabel("ROM:"); @@ -58,10 +60,10 @@ Exdeath::Exdeath(QWidget *parent) : QWidget(parent) { btnROM = new QPushButton("Select ROM"); btnApply = new QPushButton("Apply"); - layContainer->addWidget(btnApply); + layApp->addWidget(btnApply); radBase = new QRadioButton("Base"); - radFiesta = new QRadioButton("Fiesta"); + radFiesta = new QRadioButton("Jobs Unlocked"); radBalance = new QRadioButton("Balance"); radCClass = new QRadioButton("Custom Classes"); radBase->setChecked(true); @@ -98,11 +100,12 @@ Exdeath::Exdeath(QWidget *parent) : QWidget(parent) { chkLiteStep = new QCheckBox("Innate Light Step"); chkDash = new QCheckBox("Innate Dash"); chkLearning = new QCheckBox("Innate Learning"); - layDemi->addWidget(chkPassages); - layDemi->addWidget(chkPitfalls); - layDemi->addWidget(chkLiteStep); - layDemi->addWidget(chkDash); - layDemi->addWidget(chkLearning); + layInnates->addWidget(chkPassages); + layInnates->addWidget(chkPitfalls); + layInnates->addWidget(chkLiteStep); + layInnates->addWidget(chkDash); + layInnates->addWidget(chkLearning); + connect(btnROM, &QPushButton::clicked, this, &Exdeath::btnROM_clicked); connect(btnApply, &QPushButton::clicked, this, &Exdeath::btnApply_clicked); } diff --git a/src/exdeath.hh b/src/exdeath.hh index 18ab3a8..2c59e8b 100644 --- a/src/exdeath.hh +++ b/src/exdeath.hh @@ -29,7 +29,9 @@ private: QErrorMessage *error; - QVBoxLayout *layContainer; + QVBoxLayout *layApp; + QVBoxLayout *layColumns; + QGridLayout *layMain; QVBoxLayout *layMode; QGroupBox *grpMain; @@ -55,8 +57,8 @@ private: QComboBox *selNED; - QGroupBox *grpDemi; - QVBoxLayout *layDemi; + QGroupBox *grpInnates; + QVBoxLayout *layInnates; QCheckBox *chkPassages; QCheckBox *chkPitfalls;