Skip to content

armgit / krita

Public Imported from GitHub
0

Krita is a free and open source cross-platform application that offers an end-to-end solution for creating digital art files from scratch built on the KDE and Qt frameworks.

C++
887 B
Raw Blame
/*
 *  SPDX-FileCopyrightText: 2024 Wolthera van Hövell tot Westerflier <[email protected]>
 *
 *  SPDX-License-Identifier: GPL-2.0-or-later
 */
#ifndef KOFONTCHANGETRACKER_H
#define KOFONTCHANGETRACKER_H

#include <QObject>

/**
 * @brief The KoFontChangeTracker class
 * This class keeps track of the paths FontConfig is looking at,
 * and resets the font registry if they change.
 */
class KoFontChangeTracker : public QObject
{
    Q_OBJECT
public:
    explicit KoFontChangeTracker(QStringList paths, QObject *parent = nullptr);
    ~KoFontChangeTracker();

    /// This should be called after fontregistry initialization is done to start the signal compressor.
    void resetChangeTracker();
Q_SIGNALS:
    void sigUpdateConfig();
private Q_SLOTS:
    void directoriesChanged();
private:
    struct Private;
    QScopedPointer<Private> d;
};

#endif // KOFONTCHANGETRACKER_H