Provide UI Theme editor

PR #18655.
This commit is contained in:
Vladimir Golovnev 2023-03-16 10:03:05 +03:00 committed by GitHub
parent 989b1e6c2c
commit 77aa85fbd3
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
15 changed files with 1381 additions and 380 deletions

View file

@ -63,6 +63,7 @@
#include "ipsubnetwhitelistoptionsdialog.h"
#include "rss/automatedrssdownloader.h"
#include "ui_optionsdialog.h"
#include "uithemedialog.h"
#include "uithememanager.h"
#include "utils.h"
#include "watchedfolderoptionsdialog.h"
@ -323,6 +324,18 @@ void OptionsDialog::loadBehaviorTabOptions()
connect(m_ui->checkUseCustomTheme, &QGroupBox::toggled, this, &ThisType::enableApplyButton);
connect(m_ui->customThemeFilePath, &FileSystemPathEdit::selectedPathChanged, this, &ThisType::enableApplyButton);
m_ui->buttonCustomizeUITheme->setEnabled(!m_ui->checkUseCustomTheme->isChecked());
connect(m_ui->checkUseCustomTheme, &QGroupBox::toggled, this, [this]
{
m_ui->buttonCustomizeUITheme->setEnabled(!m_ui->checkUseCustomTheme->isChecked());
});
connect(m_ui->buttonCustomizeUITheme, &QPushButton::clicked, this, [this]
{
auto dialog = new UIThemeDialog(this);
dialog->setAttribute(Qt::WA_DeleteOnClose);
dialog->open();
});
connect(m_ui->confirmDeletion, &QAbstractButton::toggled, this, &ThisType::enableApplyButton);
connect(m_ui->checkAltRowColors, &QAbstractButton::toggled, this, &ThisType::enableApplyButton);
connect(m_ui->checkHideZero, &QAbstractButton::toggled, m_ui->comboHideZero, &QWidget::setEnabled);