Add a theme factory to YACReaderLibrary and theme the comic vine dialog

This commit is contained in:
luisangelsm
2026-01-14 19:58:43 +01:00
parent 1cb2f50057
commit 1bd4926b25
30 changed files with 740 additions and 178 deletions

View File

@ -1,27 +1,16 @@
#include "scraper_checkbox.h"
#include "qwidget.h"
#include "theme_manager.h"
ScraperCheckBox::ScraperCheckBox(const QString &text, QWidget *parent)
: QCheckBox(text, parent)
{
setStyleSheet(
"QCheckBox {"
" color: white;"
" font-size: 12px;"
" font-family: Arial;"
" spacing: 10px;"
"}"
"QCheckBox::indicator {"
" width: 13px;"
" height: 13px;"
" border: 1px solid #242424;"
" background: #2e2e2e;"
"}"
"QCheckBox::indicator:checked {"
" image: url(:/images/comic_vine/checkBoxTick.svg);"
" background: #2e2e2e;"
"}"
"QCheckBox::indicator:unchecked {"
" background: #2e2e2e;"
"}");
initTheme(this);
}
void ScraperCheckBox::applyTheme()
{
auto comicVineTheme = ThemeManager::instance().getCurrentTheme().comicVine;
setStyleSheet(comicVineTheme.checkBoxQSS);
}