// SPDX-License-Identifier: LGPL-2.1-only OR LGPL-3.0-only OR LicenseRef-KDE-Accepted-LGPL
// SPDX-FileCopyrightText: 2024 Arjen Hiemstra <ahiemstra@heimr.nl>
//
// This file is automatically generated from qml_group.h.j2.
// To regenerate, run `tools/propertygenerator/generate_properties.py`.

#pragma once

// clang-format off
#include <QJSValue>
#include <QObject>
#include <QProperty>
#include <qqmlregistration.h>


#include <properties/ShadowPropertyGroup.h>

#include "OffsetPropertyGroupQuick.h"
// clang-format on

namespace Union
{
namespace Quick
{

class QuickStyle;
/*!
 * \qmltype ShadowPropertyGroupQuick
 * \inqmlmodule org.kde.union.impl
 * \ingroup qtquick-properties
 *
 * \brief A group object exposing the properties of ShadowPropertyGroup to QML.
 */
class ShadowPropertyGroupQuick : public QObject
{
    Q_OBJECT
    QML_ANONYMOUS

public:
    explicit ShadowPropertyGroupQuick(QuickStyle *style);

    void update(Union::Properties::ShadowPropertyGroup *newState);
    Q_SIGNAL void updated();

    void refreshColors();

    /*!
     * \qmlproperty OffsetPropertyGroupQuick ShadowPropertyGroupQuick::offset
     *
     * Exposes ShadowPropertyGroup::OffsetPropertyGroup to QML.
     */
    Q_PROPERTY(Union::Quick::OffsetPropertyGroupQuick *offset READ offset CONSTANT)
    OffsetPropertyGroupQuick *offset() const;

    /*!
     * \qmlproperty Union::Color ShadowPropertyGroupQuick::color
     *
     * Exposes ShadowPropertyGroup::color to QML.
     */
    Q_PROPERTY(QJSValue color READ color NOTIFY colorChanged)
    QJSValue color() const;
    Q_SIGNAL void colorChanged();

    /*!
     * \qmlproperty qreal ShadowPropertyGroupQuick::size
     *
     * Exposes ShadowPropertyGroup::size to QML.
     */
    Q_PROPERTY(QJSValue size READ size NOTIFY sizeChanged)
    QJSValue size() const;
    Q_SIGNAL void sizeChanged();

    /*!
     * \qmlproperty qreal ShadowPropertyGroupQuick::blur
     *
     * Exposes ShadowPropertyGroup::blur to QML.
     */
    Q_PROPERTY(QJSValue blur READ blur NOTIFY blurChanged)
    QJSValue blur() const;
    Q_SIGNAL void blurChanged();

private:
    QuickStyle *m_style = nullptr;
    std::unique_ptr<OffsetPropertyGroupQuick> m_offset;

    Union::Properties::ShadowPropertyGroup *m_state = nullptr;
};

}
}