digiKam
Loading...
Searching...
No Matches
thememanager.h
Go to the documentation of this file.
1/* ============================================================
2 *
3 * This file is a part of digiKam project
4 * https://www.digikam.org
5 *
6 * Date : 2004-08-02
7 * Description : colors theme manager
8 *
9 * SPDX-FileCopyrightText: 2006-2024 by Gilles Caulier <caulier dot gilles at gmail dot com>
10 *
11 * SPDX-License-Identifier: GPL-2.0-or-later
12 *
13 * ============================================================ */
14
15#pragma once
16
17// Qt includes
18
19#include <QObject>
20#include <QPixmap>
21#include <QString>
22
23// Local includes
24
25#include "digikam_export.h"
26
27class QMenu;
28
29namespace Digikam
30{
31
32class DXmlGuiWindow;
33class Theme;
34
35class DIGIKAM_EXPORT ThemeManager : public QObject
36{
37 Q_OBJECT
38
39public:
40
41 ~ThemeManager() override;
42 static ThemeManager* instance();
43
44 QString currentThemeName() const;
45 void setCurrentTheme(const QString& name);
46
47 QString defaultThemeName() const;
48
49 void setThemeMenuAction(QMenu* const action);
50 void registerThemeActions(DXmlGuiWindow* const win);
51
52 void updateThemeMenu();
53
54Q_SIGNALS:
55
57
58private Q_SLOTS:
59
60 void slotChangePalette();
61
62private:
63
64 // Disable
66 explicit ThemeManager(QObject*);
67
68 void populateThemeMenu();
69 QString currentDesktopdefaultTheme() const;
70 void updateCurrentDesktopDefaultThemePreview();
71
72private:
73
74 friend class ThemeManagerCreator;
75
76 class Private;
77 Private* const d = nullptr;
78};
79
80} // namespace Digikam
Definition dxmlguiwindow.h:84
Definition thememanager_p.h:508
Definition thememanager.h:36
Definition datefolderview.cpp:34