diff options
author | Ken Moore <ken@pcbsd.org> | 2014-10-14 16:01:39 -0400 |
---|---|---|
committer | Ken Moore <ken@pcbsd.org> | 2014-10-14 16:01:39 -0400 |
commit | 6c491c85494cdcbc750491817b68396775e9b04e (patch) | |
tree | 2c3ac506fd02e73bef5240a06a648ec6f5dc03dc /libLumina/LuminaThemes.cpp | |
parent | Large update to the Lumina project: provide full theming capabilities. (diff) | |
download | lumina-6c491c85494cdcbc750491817b68396775e9b04e.tar.gz lumina-6c491c85494cdcbc750491817b68396775e9b04e.tar.bz2 lumina-6c491c85494cdcbc750491817b68396775e9b04e.zip |
Finish up the rest of the new Lumina Theme engine and the utilities for editing those themes in lumina-config. Also tag Lumina version 0.7.0 with this change.
Diffstat (limited to 'libLumina/LuminaThemes.cpp')
-rw-r--r-- | libLumina/LuminaThemes.cpp | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/libLumina/LuminaThemes.cpp b/libLumina/LuminaThemes.cpp index 8548f739..0b328502 100644 --- a/libLumina/LuminaThemes.cpp +++ b/libLumina/LuminaThemes.cpp @@ -85,13 +85,13 @@ QStringList LTHEME::availableSystemIcons(){ //returns: [name] for each item //Save a new theme/color file bool LTHEME::saveLocalTheme(QString name, QStringList contents){ QString localdir = QDir::homePath()+"/.lumina/themes/"; - if(!QFile::exists(localdir)){ QDir dir(); dir.mkpath(localdir); } + if(!QFile::exists(localdir)){ QDir dir; dir.mkpath(localdir); } return LUtils::writeFile(localdir+name+".qss.template", contents, true); } bool LTHEME::saveLocalColors(QString name, QStringList contents){ QString localdir = QDir::homePath()+"/.lumina/colors/"; - if(!QFile::exists(localdir)){ QDir dir(); dir.mkpath(localdir); } + if(!QFile::exists(localdir)){ QDir dir; dir.mkpath(localdir); } return LUtils::writeFile(localdir+name+".qss.colors", contents, true); } @@ -154,6 +154,7 @@ QString LTHEME::assembleStyleSheet(QString themepath, QString colorpath, QString else if(colors[i].startsWith("BASECOLOR=")){ stylesheet = stylesheet.replace("%%BASECOLOR%%", colors[i].section("=",1,1).simplified()); } else if(colors[i].startsWith("ALTBASECOLOR=")){ stylesheet = stylesheet.replace("%%ALTBASECOLOR%%", colors[i].section("=",1,1).simplified()); } else if(colors[i].startsWith("TEXTCOLOR=")){ stylesheet = stylesheet.replace("%%TEXTCOLOR%%", colors[i].section("=",1,1).simplified()); } + else if(colors[i].startsWith("TEXTDISABLECOLOR=")){ stylesheet = stylesheet.replace("%%TEXTDISABLECOLOR%%", colors[i].section("=",1,1).simplified()); } else if(colors[i].startsWith("TEXTHIGHLIGHTCOLOR=")){ stylesheet = stylesheet.replace("%%TEXTHIGHLIGHTCOLOR%%", colors[i].section("=",1,1).simplified()); } } stylesheet = stylesheet.replace("%%FONT%%", font); |