GrantleeTheme

grantleetheme.h
1 /*
2  Copyright (c) 2013-2020 Laurent Montel <[email protected]>
3 
4  This library is free software; you can redistribute it and/or
5  modify it under the terms of the GNU Lesser General Public
6  License as published by the Free Software Foundation; either
7  version 2.1 of the License, or (at your option) any later version.
8 
9  This library is distributed in the hope that it will be useful,
10  but WITHOUT ANY WARRANTY; without even the implied warranty of
11  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12  Lesser General Public License for more details.
13 
14  You should have received a copy of the GNU Lesser General Public
15  License along with this library; if not, write to the Free Software
16  Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
17 */
18 #ifndef GRANTLEETHEME_H
19 #define GRANTLEETHEME_H
20 
21 #include "grantleetheme_export.h"
22 
23 #include <QString>
24 #include <QStringList>
25 #include <QVariantHash>
26 #include <QSharedDataPointer>
27 
28 class GrantleeThemeTest;
29 
30 namespace GrantleeTheme {
31 class ThemeManager;
32 class ThemePrivate;
36 class GRANTLEETHEME_EXPORT Theme
37 {
38 public:
39  explicit Theme();
40  Theme(const Theme &other);
41  ~Theme();
42 
43  Q_REQUIRED_RESULT bool operator==(const Theme &other) const;
44  Theme &operator=(const Theme &other);
45 
46  Q_REQUIRED_RESULT bool isValid() const;
47 
48  Q_REQUIRED_RESULT QString description() const;
49  Q_REQUIRED_RESULT QString themeFilename() const;
50  Q_REQUIRED_RESULT QString name() const;
51  Q_REQUIRED_RESULT QStringList displayExtraVariables() const;
52  Q_REQUIRED_RESULT QString dirName() const;
53  Q_REQUIRED_RESULT QString absolutePath() const;
54  Q_REQUIRED_RESULT QString author() const;
55  Q_REQUIRED_RESULT QString authorEmail() const;
56 
57  void addThemePath(const QString &path);
58 
59  Q_REQUIRED_RESULT QString render(const QString &templateName, const QVariantHash &data, const QByteArray &applicationDomain = QByteArray());
60 
61  static void addPluginPath(const QString &path);
62 
63 private:
64  friend class ::GrantleeThemeTest;
65  friend class ThemeManager;
66  Theme(const QString &themePath, const QString &dirName, const QString &defaultDesktopFileName);
67 
69 };
70 }
71 
72 #endif // GRANTLEETHEME_H
The ThemeManager class.
The Theme class.
Definition: grantleetheme.h:36
This file is part of the KDE documentation.
Documentation copyright © 1996-2020 The KDE developers.
Generated on Tue Jun 2 2020 23:12:01 by doxygen 1.8.11 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.