Warning, file /network/tokodon/src/utils/colorschemer.h was not indexed or was modified since last indexation (in which case cross-reference links may be missing, inaccurate or erroneous).

0001 // SPDX-FileCopyrightText: 2021 Carl Schwan <carlschwan@kde.org>
0002 // SPDX-License-Identifier: LGPL-2.1-or-later
0003 
0004 #pragma once
0005 
0006 #include <QObject>
0007 
0008 class QAbstractItemModel;
0009 class KColorSchemeManager;
0010 
0011 class ColorSchemer : public QObject
0012 {
0013     Q_OBJECT
0014     Q_PROPERTY(QAbstractItemModel *model READ model CONSTANT)
0015 public:
0016     explicit ColorSchemer(QObject *parent = nullptr);
0017 
0018     QAbstractItemModel *model() const;
0019     Q_INVOKABLE void apply(int idx);
0020     Q_INVOKABLE void apply(const QString &name);
0021     Q_INVOKABLE int indexForScheme(const QString &name) const;
0022     Q_INVOKABLE QString nameForIndex(int index) const;
0023 
0024 private:
0025     KColorSchemeManager *c;
0026 };