Allow styling with QSS stylesheets

This commit is contained in:
Prince Gupta 2019-07-09 19:56:55 +05:30
parent 33b225ac6d
commit a24925c858
10 changed files with 292 additions and 56 deletions

View file

@ -105,6 +105,27 @@ void Preferences::setLocale(const QString &locale)
setValue("Preferences/General/Locale", locale);
}
bool Preferences::useCustomUITheme() const
{
return value("Preferences/General/UseCustomUITheme", false).toBool()
&& !customUIThemePath().isEmpty();
}
void Preferences::setUseCustomUITheme(const bool use)
{
setValue("Preferences/General/UseCustomUITheme", use);
}
QString Preferences::customUIThemePath() const
{
return value("Preferences/General/CustomUIThemePath").toString();
}
void Preferences::setCustomUIThemePath(const QString &path)
{
setValue("Preferences/General/CustomUIThemePath", path);
}
bool Preferences::deleteTorrentFilesAsDefault() const
{
return value("Preferences/General/DeleteTorrentsFilesAsDefault", false).toBool();