summaryrefslogtreecommitdiffstats
path: root/kdecore
diff options
context:
space:
mode:
authortpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2011-01-23 05:12:43 +0000
committertpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2011-01-23 05:12:43 +0000
commita20928b6bfae18a41bb42b85e10f73fb63548ccc (patch)
treee0cdc70ad0064256ebf5c3e8a91d84048176ef99 /kdecore
parent865c5ed0c595c95574e4f8f34b578c46f10aa0ff (diff)
downloadtdelibs-a20928b6bfae18a41bb42b85e10f73fb63548ccc.tar.gz
tdelibs-a20928b6bfae18a41bb42b85e10f73fb63548ccc.zip
Styles are now mostly functional under Qt4
git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdelibs@1216403 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'kdecore')
-rw-r--r--kdecore/kapplication.cpp16
-rw-r--r--kdecore/kglobalsettings.cpp8
2 files changed, 19 insertions, 5 deletions
diff --git a/kdecore/kapplication.cpp b/kdecore/kapplication.cpp
index bad196482..07260813c 100644
--- a/kdecore/kapplication.cpp
+++ b/kdecore/kapplication.cpp
@@ -1510,15 +1510,29 @@ void KApplication::parseCommandLine( )
if (args->isSet("style"))
{
+ TQStringList plugins = KGlobal::dirs()->resourceDirs( "qtplugins" );
+ TQStringList::Iterator itp = plugins.begin();
+ while (itp != plugins.end()) {
+ addLibraryPath( *itp );
+ ++itp;
+ }
+
TQStringList styles = TQStyleFactory::keys();
TQString reqStyle(args->getOption("style").lower());
- for (TQStringList::ConstIterator it = styles.begin(); it != styles.end(); ++it)
+ TQStringList list = libraryPaths();
+ TQStringList::Iterator it = list.begin();
+ while( it != list.end() ) {
+ ++it;
+ }
+
+ for (TQStringList::ConstIterator it = styles.begin(); it != styles.end(); ++it) {
if ((*it).lower() == reqStyle)
{
d->overrideStyle = *it;
break;
}
+ }
if (d->overrideStyle.isEmpty())
fprintf(stderr, "%s", TQString(i18n("The style %1 was not found\n").arg(reqStyle)).local8Bit().data());
diff --git a/kdecore/kglobalsettings.cpp b/kdecore/kglobalsettings.cpp
index 3595dce4c..f78377cfe 100644
--- a/kdecore/kglobalsettings.cpp
+++ b/kdecore/kglobalsettings.cpp
@@ -265,7 +265,7 @@ TQColor KGlobalSettings::buttonTextColor()
}
// IMPORTANT:
-// This function should be get in sync with
+// This function should be kept in sync with
// KApplication::kdisplaySetPalette()
TQColor KGlobalSettings::baseColor()
{
@@ -274,7 +274,7 @@ TQColor KGlobalSettings::baseColor()
}
// IMPORTANT:
-// This function should be get in sync with
+// This function should be kept in sync with
// KApplication::kdisplaySetPalette()
TQColor KGlobalSettings::textColor()
{
@@ -283,7 +283,7 @@ TQColor KGlobalSettings::textColor()
}
// IMPORTANT:
-// This function should be get in sync with
+// This function should be kept in sync with
// KApplication::kdisplaySetPalette()
TQColor KGlobalSettings::highlightedTextColor()
{
@@ -292,7 +292,7 @@ TQColor KGlobalSettings::highlightedTextColor()
}
// IMPORTANT:
-// This function should be get in sync with
+// This function should be kept in sync with
// KApplication::kdisplaySetPalette()
TQColor KGlobalSettings::highlightColor()
{