summaryrefslogtreecommitdiffstats
path: root/ksplashml/themeengine/objkstheme.h
diff options
context:
space:
mode:
authortoma <toma@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2009-11-25 17:56:58 +0000
committertoma <toma@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2009-11-25 17:56:58 +0000
commit4aed2c8219774f5d797760606b8489a92ddc5163 (patch)
tree3f8c130f7d269626bf6a9447407ef6c35954426a /ksplashml/themeengine/objkstheme.h
downloadtdebase-4aed2c8219774f5d797760606b8489a92ddc5163.tar.gz
tdebase-4aed2c8219774f5d797760606b8489a92ddc5163.zip
Copy the KDE 3.5 branch to branches/trinity for new KDE 3.5 features.
BUG:215923 git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdebase@1054174 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'ksplashml/themeengine/objkstheme.h')
-rw-r--r--ksplashml/themeengine/objkstheme.h70
1 files changed, 70 insertions, 0 deletions
diff --git a/ksplashml/themeengine/objkstheme.h b/ksplashml/themeengine/objkstheme.h
new file mode 100644
index 000000000..9685d4529
--- /dev/null
+++ b/ksplashml/themeengine/objkstheme.h
@@ -0,0 +1,70 @@
+/***************************************************************************
+ * Copyright Brian Ledbetter 2001-2003 <[email protected]> *
+ * Copyright Ravikiran Rajagopal 2003 <[email protected]> *
+ * *
+ * This program is free software; you can redistribute it and/or modify *
+ * it under the terms of the GNU General Public License (version 2) as *
+ * published by the Free Software Foundation. (The original KSplash/ML *
+ * codebase (upto version 0.95.3) is BSD-licensed.) *
+ * *
+ ***************************************************************************/
+
+#ifndef __OBJKSTHEME_H__
+#define __OBJKSTHEME_H__
+
+#include <kcmdlineargs.h>
+
+#include <qstring.h>
+#include <qstringlist.h>
+
+class KConfig;
+/**
+ * @short Theme reader.
+ * A Theme is read in from the file
+ * <KDEDIR>/share/apps/ksplash/Themes/<theme>/Theme.rc
+ * This controls the behavior, graphics, and appearance
+ * of KSplash completely, and offers a friendlier way
+ * of installing custom splash screens.
+ */
+class KDE_EXPORT ObjKsTheme : public QObject
+{
+ Q_OBJECT
+public:
+ explicit ObjKsTheme( const QString& );
+ virtual ~ObjKsTheme();
+
+ void loadCmdLineArgs( KCmdLineArgs * );
+
+ QString theme() const { return( mActiveTheme ); }
+ QString themeEngine() const { return( mThemeEngine ); }
+ KConfig *themeConfig() const { return( mThemeConfig ); }
+ QString themeDir() const { return( mThemeDir ); }
+ bool loColor() const { return( mLoColor ); }
+ bool testing() const { return( mTesting ); }
+ bool managedMode() const { return( mManagedMode ); }
+ QString icon( int i ) { return (m_icons[i-1].isNull()?(QString::null):m_icons[i-1]); }
+ QString text( int i ) { return (m_text[i-1].isNull()?(QString::null):m_text[i-1]); }
+ QString locateThemeData( const QString &resource );
+ int xineramaScreen() const { return mXineramaScreen; }
+
+protected:
+ bool loadThemeRc( const QString&, bool );
+ bool loadLocalConfig( const QString&, bool );
+ bool loadKConfig( KConfig *, const QString&, bool );
+
+private:
+ QString mActiveTheme, mThemeDir;
+ KConfig *mThemeConfig;
+
+ int mXineramaScreen;
+ bool mLoColor, mTesting, mManagedMode;
+ QString mThemeEngine;
+ QString mThemePrefix;
+
+ QStringList m_icons, m_text;
+
+ class ObjKsThemePrivate;
+ ObjKsThemePrivate *d;
+};
+
+#endif