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

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

class Settings : public KConfigSkeleton
{
  public:

    static Settings *self();
    static void instance(const QString& cfgfilename);
    static void instance(KSharedConfig::Ptr config);
    ~Settings() override;

    /**
      Set showboundlines
    */
    static
    void setShowBoundLines( bool v )
    {
      if (!self()->isShowBoundLinesImmutable())
        self()->mShowBoundLines = v;
    }

    /**
      Get showboundlines
    */
    static
    bool showBoundLines()
    {
      return self()->mShowBoundLines;
    }

    /**
      Is showboundlines Immutable
    */
    static
    bool isShowBoundLinesImmutable()
    {
      return self()->isImmutable( QStringLiteral( "ShowBoundLines" ) );
    }

    /**
      Set enableanimation
    */
    static
    void setEnableAnimation( bool v )
    {
      if (!self()->isEnableAnimationImmutable())
        self()->mEnableAnimation = v;
    }

    /**
      Get enableanimation
    */
    static
    bool enableAnimation()
    {
      return self()->mEnableAnimation;
    }

    /**
      Is enableanimation Immutable
    */
    static
    bool isEnableAnimationImmutable()
    {
      return self()->isImmutable( QStringLiteral( "EnableAnimation" ) );
    }

    /**
      Set enablehighlight
    */
    static
    void setEnableHighlight( bool v )
    {
      if (!self()->isEnableHighlightImmutable())
        self()->mEnableHighlight = v;
    }

    /**
      Get enablehighlight
    */
    static
    bool enableHighlight()
    {
      return self()->mEnableHighlight;
    }

    /**
      Is enablehighlight Immutable
    */
    static
    bool isEnableHighlightImmutable()
    {
      return self()->isImmutable( QStringLiteral( "EnableHighlight" ) );
    }

    /**
      Set enablesounds
    */
    static
    void setEnableSounds( bool v )
    {
      if (!self()->isEnableSoundsImmutable())
        self()->mEnableSounds = v;
    }

    /**
      Get enablesounds
    */
    static
    bool enableSounds()
    {
      return self()->mEnableSounds;
    }

    /**
      Is enablesounds Immutable
    */
    static
    bool isEnableSoundsImmutable()
    {
      return self()->isImmutable( QStringLiteral( "EnableSounds" ) );
    }

    /**
      Set RadioTheme
    */
    static
    void setRadioTheme( bool v )
    {
      if (!self()->isRadioThemeImmutable())
        self()->mRadioTheme = v;
    }

    /**
      Get RadioTheme
    */
    static
    bool radioTheme()
    {
      return self()->mRadioTheme;
    }

    /**
      Is RadioTheme Immutable
    */
    static
    bool isRadioThemeImmutable()
    {
      return self()->isImmutable( QStringLiteral( "RadioTheme" ) );
    }

    /**
      Set RadioColor
    */
    static
    void setRadioColor( bool v )
    {
      if (!self()->isRadioColorImmutable())
        self()->mRadioColor = v;
    }

    /**
      Get RadioColor
    */
    static
    bool radioColor()
    {
      return self()->mRadioColor;
    }

    /**
      Is RadioColor Immutable
    */
    static
    bool isRadioColorImmutable()
    {
      return self()->isImmutable( QStringLiteral( "RadioColor" ) );
    }

    /**
      Set RadioImage
    */
    static
    void setRadioImage( bool v )
    {
      if (!self()->isRadioImageImmutable())
        self()->mRadioImage = v;
    }

    /**
      Get RadioImage
    */
    static
    bool radioImage()
    {
      return self()->mRadioImage;
    }

    /**
      Is RadioImage Immutable
    */
    static
    bool isRadioImageImmutable()
    {
      return self()->isImmutable( QStringLiteral( "RadioImage" ) );
    }

    /**
      Set The background color to be used.
    */
    static
    void setBgColor( const QColor & v )
    {
      if (!self()->isBgColorImmutable())
        self()->mBgColor = v;
    }

    /**
      Get The background color to be used.
    */
    static
    QColor bgColor()
    {
      return self()->mBgColor;
    }

    /**
      Is The background color to be used. Immutable
    */
    static
    bool isBgColorImmutable()
    {
      return self()->isImmutable( QStringLiteral( "BgColor" ) );
    }

    /**
      Set The background image to be used.
    */
    static
    void setBgImage( const QUrl & v )
    {
      if (!self()->isBgImageImmutable())
        self()->mBgImage = v;
    }

    /**
      Get The background image to be used.
    */
    static
    QUrl bgImage()
    {
      return self()->mBgImage;
    }

    /**
      Is The background image to be used. Immutable
    */
    static
    bool isBgImageImmutable()
    {
      return self()->isImmutable( QStringLiteral( "BgImage" ) );
    }

    /**
      Set The width of the playing field.
    */
    static
    void setCustomWidth( int v )
    {
      if (v < 5)
      {
        qDebug() << "setCustomWidth: value " << v << " is less than the minimum value of 5";
        v = 5;
      }

      if (v > 50)
      {
        qDebug() << "setCustomWidth: value " << v << " is greater than the maximum value of 50";
        v = 50;
      }

      if (!self()->isCustomWidthImmutable())
        self()->mCustomWidth = v;
    }

    /**
      Get The width of the playing field.
    */
    static
    int customWidth()
    {
      return self()->mCustomWidth;
    }

    /**
      Is The width of the playing field. Immutable
    */
    static
    bool isCustomWidthImmutable()
    {
      return self()->isImmutable( QStringLiteral( "CustomWidth" ) );
    }

    /**
      Set The height of the playing field.
    */
    static
    void setCustomHeight( int v )
    {
      if (v < 5)
      {
        qDebug() << "setCustomHeight: value " << v << " is less than the minimum value of 5";
        v = 5;
      }

      if (v > 50)
      {
        qDebug() << "setCustomHeight: value " << v << " is greater than the maximum value of 50";
        v = 50;
      }

      if (!self()->isCustomHeightImmutable())
        self()->mCustomHeight = v;
    }

    /**
      Get The height of the playing field.
    */
    static
    int customHeight()
    {
      return self()->mCustomHeight;
    }

    /**
      Is The height of the playing field. Immutable
    */
    static
    bool isCustomHeightImmutable()
    {
      return self()->isImmutable( QStringLiteral( "CustomHeight" ) );
    }

    /**
      Set The number of colors in the playing field.
    */
    static
    void setCustomColorCount( int v )
    {
      if (v < 1)
      {
        qDebug() << "setCustomColorCount: value " << v << " is less than the minimum value of 1";
        v = 1;
      }
      if (!self()->isCustomColorCountImmutable())
        self()->mCustomColorCount = v;
    }

    /**
      Get The number of colors in the playing field.
    */
    static
    int customColorCount()
    {
      return self()->mCustomColorCount;
    }

    /**
      Is The number of colors in the playing field. Immutable
    */
    static
    bool isCustomColorCountImmutable()
    {
      return self()->isImmutable( QStringLiteral( "CustomColorCount" ) );
    }

  protected:
    Settings(KSharedConfig::Ptr config);
    friend class SettingsHelper;


    // General
    bool mShowBoundLines;
    bool mEnableAnimation;
    bool mEnableHighlight;
    bool mEnableSounds;

    // Background
    bool mRadioTheme;
    bool mRadioColor;
    bool mRadioImage;
    QColor mBgColor;
    QUrl mBgImage;

    // CustomGame
    int mCustomWidth;
    int mCustomHeight;
    int mCustomColorCount;
};

#endif

