QGIS API Documentation 3.99.0-Master (a8882ad4560)
Loading...
Searching...
No Matches
qgsapplicationthemeregistry.h
Go to the documentation of this file.
1/***************************************************************************
2 qgsapplicationthemeregistry.h
3 ------------------------
4 begin : January 2026
5 copyright : (C) 2026 by Mathieu Pellerin
6 email : mathieu at opengis dot ch
7 ***************************************************************************/
8
9/***************************************************************************
10 * *
11 * This program is free software; you can redistribute it and/or modify *
12 * it under the terms of the GNU General Public License as published by *
13 * the Free Software Foundation; either version 2 of the License, or *
14 * (at your option) any later version. *
15 * *
16 ***************************************************************************/
17
18#ifndef QGSUSERINTERFACETHEMEREGISTRY_H
19#define QGSUSERINTERFACETHEMEREGISTRY_H
20
21#include "qgis_core.h"
22
23#include <QList>
24
36{
37
38 public:
39
44
46
54 bool addTheme( const QString &name, const QString &folder );
55
62 bool removeTheme( const QString &name );
63
67 QStringList themes() const;
68
72 QString themeFolder( const QString &name ) const;
73
77 QHash<QString, QString> themeFolders() const;
78
79 private:
80
84 void addApplicationThemes();
85
86 QHash<QString, QString> mThemes;
87
88};
89
90#endif
QHash< QString, QString > themeFolders() const
Returns a map of user interface theme names and folders.
QgsApplicationThemeRegistry()
Constructor for an empty user interface theme registry.
QStringList themes() const
Returns the list of available user interface themes.
QString themeFolder(const QString &name) const
Returns the user interface theme folder for a matching name.
bool addTheme(const QString &name, const QString &folder)
Adds a user interface theme into the registry.
bool removeTheme(const QString &name)
Removes a user interface theme with a matching name from the registry.
~QgsApplicationThemeRegistry()=default