// This file is generated by kconfig_compiler_kf6 from config.kcfg.
// All changes you do to this file will be lost.
#ifndef CONFIG_H
#define CONFIG_H

#include <kconfigskeleton.h>
#include <QCoreApplication>
#include <QDebug>
#include <qqmlintegration.h>

#include <QStandardPaths>

class QQmlEngine;
class QJSEngine;

class Config : public KConfigSkeleton
{
  Q_OBJECT
  QML_ELEMENT
  QML_SINGLETON
  public:

    static Config *self();
    static Config *create(QQmlEngine *, QJSEngine *);
    ~Config() override;

    /**
      Set Location where to search for books
    */
    static
    void setBookLocations( const QStringList & v )
    {
      if (v != self()->mBookLocations && !self()->isBookLocationsImmutable()) {
        self()->mBookLocations = v;
        Q_EMIT self()->bookLocationsChanged();
      }
    }

    Q_PROPERTY(QStringList bookLocations READ bookLocations WRITE setBookLocations NOTIFY bookLocationsChanged)
    Q_PROPERTY(bool isBookLocationsImmutable READ isBookLocationsImmutable CONSTANT)
    Q_PROPERTY(QStringList defaultBookLocationsValue READ defaultBookLocationsValue CONSTANT)
    /**
      Get Location where to search for books
    */
    static
    QStringList bookLocations()
    {
      return self()->mBookLocations;
    }

    /**
      Is Location where to search for books Immutable
    */
    static
    bool isBookLocationsImmutable()
    {
      return self()->isImmutable( QStringLiteral( "bookLocations" ) );
    }

    /**
      Get Location where to search for books default value
    */
    static
    QStringList defaultBookLocationsValue()
    {
        return defaultBookLocationsValue_helper();
    }

    /**
      Set Default font
    */
    static
    void setDefaultFont( const QFont & v )
    {
      if (v != self()->mDefaultFont && !self()->isDefaultFontImmutable()) {
        self()->mDefaultFont = v;
        Q_EMIT self()->defaultFontChanged();
      }
    }

    Q_PROPERTY(QFont defaultFont READ defaultFont WRITE setDefaultFont NOTIFY defaultFontChanged)
    Q_PROPERTY(bool isDefaultFontImmutable READ isDefaultFontImmutable CONSTANT)
    Q_PROPERTY(QFont defaultDefaultFontValue READ defaultDefaultFontValue CONSTANT)
    /**
      Get Default font
    */
    static
    QFont defaultFont()
    {
      return self()->mDefaultFont;
    }

    /**
      Is Default font Immutable
    */
    static
    bool isDefaultFontImmutable()
    {
      return self()->isImmutable( QStringLiteral( "defaultFont" ) );
    }

    /**
      Get Default font default value
    */
    static
    QFont defaultDefaultFontValue()
    {
        return defaultDefaultFontValue_helper();
    }

    /**
      Set Use publisher font
    */
    static
    void setUsePublisherFont( bool v )
    {
      if (v != self()->mUsePublisherFont && !self()->isUsePublisherFontImmutable()) {
        self()->mUsePublisherFont = v;
        Q_EMIT self()->usePublisherFontChanged();
      }
    }

    Q_PROPERTY(bool usePublisherFont READ usePublisherFont WRITE setUsePublisherFont NOTIFY usePublisherFontChanged)
    Q_PROPERTY(bool isUsePublisherFontImmutable READ isUsePublisherFontImmutable CONSTANT)
    Q_PROPERTY(bool defaultUsePublisherFontValue READ defaultUsePublisherFontValue CONSTANT)
    /**
      Get Use publisher font
    */
    static
    bool usePublisherFont()
    {
      return self()->mUsePublisherFont;
    }

    /**
      Is Use publisher font Immutable
    */
    static
    bool isUsePublisherFontImmutable()
    {
      return self()->isImmutable( QStringLiteral( "usePublisherFont" ) );
    }

    /**
      Get Use publisher font default value
    */
    static
    bool defaultUsePublisherFontValue()
    {
        return defaultUsePublisherFontValue_helper();
    }

    /**
      Set Invert colors
    */
    static
    void setInvert( bool v )
    {
      if (v != self()->mInvert && !self()->isInvertImmutable()) {
        self()->mInvert = v;
        Q_EMIT self()->invertChanged();
      }
    }

    Q_PROPERTY(bool invert READ invert WRITE setInvert NOTIFY invertChanged)
    Q_PROPERTY(bool isInvertImmutable READ isInvertImmutable CONSTANT)
    Q_PROPERTY(bool defaultInvertValue READ defaultInvertValue CONSTANT)
    /**
      Get Invert colors
    */
    static
    bool invert()
    {
      return self()->mInvert;
    }

    /**
      Is Invert colors Immutable
    */
    static
    bool isInvertImmutable()
    {
      return self()->isImmutable( QStringLiteral( "invert" ) );
    }

    /**
      Get Invert colors default value
    */
    static
    bool defaultInvertValue()
    {
        return defaultInvertValue_helper();
    }

    /**
      Set Justify text
    */
    static
    void setJustify( bool v )
    {
      if (v != self()->mJustify && !self()->isJustifyImmutable()) {
        self()->mJustify = v;
        Q_EMIT self()->justifyChanged();
      }
    }

    Q_PROPERTY(bool justify READ justify WRITE setJustify NOTIFY justifyChanged)
    Q_PROPERTY(bool isJustifyImmutable READ isJustifyImmutable CONSTANT)
    Q_PROPERTY(bool defaultJustifyValue READ defaultJustifyValue CONSTANT)
    /**
      Get Justify text
    */
    static
    bool justify()
    {
      return self()->mJustify;
    }

    /**
      Is Justify text Immutable
    */
    static
    bool isJustifyImmutable()
    {
      return self()->isImmutable( QStringLiteral( "justify" ) );
    }

    /**
      Get Justify text default value
    */
    static
    bool defaultJustifyValue()
    {
        return defaultJustifyValue_helper();
    }

    /**
      Set Hyphenate text
    */
    static
    void setHyphenate( bool v )
    {
      if (v != self()->mHyphenate && !self()->isHyphenateImmutable()) {
        self()->mHyphenate = v;
        Q_EMIT self()->hyphenateChanged();
      }
    }

    Q_PROPERTY(bool hyphenate READ hyphenate WRITE setHyphenate NOTIFY hyphenateChanged)
    Q_PROPERTY(bool isHyphenateImmutable READ isHyphenateImmutable CONSTANT)
    Q_PROPERTY(bool defaultHyphenateValue READ defaultHyphenateValue CONSTANT)
    /**
      Get Hyphenate text
    */
    static
    bool hyphenate()
    {
      return self()->mHyphenate;
    }

    /**
      Is Hyphenate text Immutable
    */
    static
    bool isHyphenateImmutable()
    {
      return self()->isImmutable( QStringLiteral( "hyphenate" ) );
    }

    /**
      Get Hyphenate text default value
    */
    static
    bool defaultHyphenateValue()
    {
        return defaultHyphenateValue_helper();
    }

    /**
      Set Line-height
    */
    static
    void setSpacing( double v )
    {
      if (v != self()->mSpacing && !self()->isSpacingImmutable()) {
        self()->mSpacing = v;
        Q_EMIT self()->spacingChanged();
      }
    }

    Q_PROPERTY(double spacing READ spacing WRITE setSpacing NOTIFY spacingChanged)
    Q_PROPERTY(bool isSpacingImmutable READ isSpacingImmutable CONSTANT)
    Q_PROPERTY(double defaultSpacingValue READ defaultSpacingValue CONSTANT)
    /**
      Get Line-height
    */
    static
    double spacing()
    {
      return self()->mSpacing;
    }

    /**
      Is Line-height Immutable
    */
    static
    bool isSpacingImmutable()
    {
      return self()->isImmutable( QStringLiteral( "spacing" ) );
    }

    /**
      Get Line-height default value
    */
    static
    double defaultSpacingValue()
    {
        return defaultSpacingValue_helper();
    }

    /**
      Set Brightness
    */
    static
    void setBrightness( double v )
    {
      if (v != self()->mBrightness && !self()->isBrightnessImmutable()) {
        self()->mBrightness = v;
        Q_EMIT self()->brightnessChanged();
      }
    }

    Q_PROPERTY(double brightness READ brightness WRITE setBrightness NOTIFY brightnessChanged)
    Q_PROPERTY(bool isBrightnessImmutable READ isBrightnessImmutable CONSTANT)
    Q_PROPERTY(double defaultBrightnessValue READ defaultBrightnessValue CONSTANT)
    /**
      Get Brightness
    */
    static
    double brightness()
    {
      return self()->mBrightness;
    }

    /**
      Is Brightness Immutable
    */
    static
    bool isBrightnessImmutable()
    {
      return self()->isImmutable( QStringLiteral( "brightness" ) );
    }

    /**
      Get Brightness default value
    */
    static
    double defaultBrightnessValue()
    {
        return defaultBrightnessValue_helper();
    }

    /**
      Set Max width
    */
    static
    void setMaxWidth( int v )
    {
      if (v != self()->mMaxWidth && !self()->isMaxWidthImmutable()) {
        self()->mMaxWidth = v;
        Q_EMIT self()->maxWidthChanged();
      }
    }

    Q_PROPERTY(int maxWidth READ maxWidth WRITE setMaxWidth NOTIFY maxWidthChanged)
    Q_PROPERTY(bool isMaxWidthImmutable READ isMaxWidthImmutable CONSTANT)
    Q_PROPERTY(int defaultMaxWidthValue READ defaultMaxWidthValue CONSTANT)
    /**
      Get Max width
    */
    static
    int maxWidth()
    {
      return self()->mMaxWidth;
    }

    /**
      Is Max width Immutable
    */
    static
    bool isMaxWidthImmutable()
    {
      return self()->isImmutable( QStringLiteral( "maxWidth" ) );
    }

    /**
      Get Max width default value
    */
    static
    int defaultMaxWidthValue()
    {
        return defaultMaxWidthValue_helper();
    }

    /**
      Set Margin
    */
    static
    void setMargin( int v )
    {
      if (v != self()->mMargin && !self()->isMarginImmutable()) {
        self()->mMargin = v;
        Q_EMIT self()->marginChanged();
      }
    }

    Q_PROPERTY(int margin READ margin WRITE setMargin NOTIFY marginChanged)
    Q_PROPERTY(bool isMarginImmutable READ isMarginImmutable CONSTANT)
    Q_PROPERTY(int defaultMarginValue READ defaultMarginValue CONSTANT)
    /**
      Get Margin
    */
    static
    int margin()
    {
      return self()->mMargin;
    }

    /**
      Is Margin Immutable
    */
    static
    bool isMarginImmutable()
    {
      return self()->isImmutable( QStringLiteral( "margin" ) );
    }

    /**
      Get Margin default value
    */
    static
    int defaultMarginValue()
    {
        return defaultMarginValue_helper();
    }

    /**
      Set Show progress
    */
    static
    void setShowProgress( bool v )
    {
      if (v != self()->mShowProgress && !self()->isShowProgressImmutable()) {
        self()->mShowProgress = v;
        Q_EMIT self()->showProgressChanged();
      }
    }

    Q_PROPERTY(bool showProgress READ showProgress WRITE setShowProgress NOTIFY showProgressChanged)
    Q_PROPERTY(bool isShowProgressImmutable READ isShowProgressImmutable CONSTANT)
    Q_PROPERTY(bool defaultShowProgressValue READ defaultShowProgressValue CONSTANT)
    /**
      Get Show progress
    */
    static
    bool showProgress()
    {
      return self()->mShowProgress;
    }

    /**
      Is Show progress Immutable
    */
    static
    bool isShowProgressImmutable()
    {
      return self()->isImmutable( QStringLiteral( "showProgress" ) );
    }

    /**
      Get Show progress default value
    */
    static
    bool defaultShowProgressValue()
    {
        return defaultShowProgressValue_helper();
    }


    enum {
      signalBookLocationsChanged = 1,
      signalDefaultFontChanged = 2,
      signalUsePublisherFontChanged = 3,
      signalInvertChanged = 4,
      signalJustifyChanged = 5,
      signalHyphenateChanged = 6,
      signalSpacingChanged = 7,
      signalBrightnessChanged = 8,
      signalMaxWidthChanged = 9,
      signalMarginChanged = 10,
      signalShowProgressChanged = 11
    };

  Q_SIGNALS:
    void bookLocationsChanged();

    void defaultFontChanged();

    void usePublisherFontChanged();

    void invertChanged();

    void justifyChanged();

    void hyphenateChanged();

    void spacingChanged();

    void brightnessChanged();

    void maxWidthChanged();

    void marginChanged();

    void showProgressChanged();

  private:
    void itemChanged(quint64 signalFlag);

  protected:
    Config(QObject *parent = nullptr);
    friend class ConfigHelper;


    // General
    QStringList mBookLocations;
    static QStringList defaultBookLocationsValue_helper();

    // Appearance
    QFont mDefaultFont;
    static QFont defaultDefaultFontValue_helper();
    bool mUsePublisherFont;
    static bool defaultUsePublisherFontValue_helper();
    bool mInvert;
    static bool defaultInvertValue_helper();
    bool mJustify;
    static bool defaultJustifyValue_helper();
    bool mHyphenate;
    static bool defaultHyphenateValue_helper();
    double mSpacing;
    static double defaultSpacingValue_helper();
    double mBrightness;
    static double defaultBrightnessValue_helper();
    int mMaxWidth;
    static int defaultMaxWidthValue_helper();
    int mMargin;
    static int defaultMarginValue_helper();
    bool mShowProgress;
    static bool defaultShowProgressValue_helper();
};

#endif

