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

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

class Prefs : public KConfigSkeleton
{
  public:
    class EnumSkill1
    {
      public:
      enum type { Beginner, Novice, Average, Strong, Expert, COUNT };
    };
    class EnumSkill2
    {
      public:
      enum type { Beginner, Novice, Average, Strong, Expert, COUNT };
    };

    static Prefs *self();
    ~Prefs() override;

    /**
      Get Animation speed of overflowing dice
    */
    static
    int animationSpeed()
    {
      return self()->mAnimationSpeed;
    }

    /**
      Is Animation speed of overflowing dice Immutable
    */
    static
    bool isAnimationSpeedImmutable()
    {
      return self()->isImmutable( QStringLiteral( "AnimationSpeed" ) );
    }

    /**
      Get Animation type None (no pauses).
    */
    static
    bool animationNone()
    {
      return self()->mAnimationNone;
    }

    /**
      Is Animation type None (no pauses). Immutable
    */
    static
    bool isAnimationNoneImmutable()
    {
      return self()->isImmutable( QStringLiteral( "AnimationNone" ) );
    }

    /**
      Get Animation type Darken and pause.
    */
    static
    bool animationDelay()
    {
      return self()->mAnimationDelay;
    }

    /**
      Is Animation type Darken and pause. Immutable
    */
    static
    bool isAnimationDelayImmutable()
    {
      return self()->isImmutable( QStringLiteral( "AnimationDelay" ) );
    }

    /**
      Get Animation type Blink rapidly.
    */
    static
    bool animationBlink()
    {
      return self()->mAnimationBlink;
    }

    /**
      Is Animation type Blink rapidly. Immutable
    */
    static
    bool isAnimationBlinkImmutable()
    {
      return self()->isImmutable( QStringLiteral( "AnimationBlink" ) );
    }

    /**
      Get Animation type Scatter dots.
    */
    static
    bool animationSpread()
    {
      return self()->mAnimationSpread;
    }

    /**
      Is Animation type Scatter dots. Immutable
    */
    static
    bool isAnimationSpreadImmutable()
    {
      return self()->isImmutable( QStringLiteral( "AnimationSpread" ) );
    }

    /**
      Get Color of neutral cubes.
    */
    static
    QColor color0()
    {
      return self()->mColor0;
    }

    /**
      Is Color of neutral cubes. Immutable
    */
    static
    bool isColor0Immutable()
    {
      return self()->isImmutable( QStringLiteral( "Color0" ) );
    }

    /**
      Get Color of player 1.
    */
    static
    QColor color1()
    {
      return self()->mColor1;
    }

    /**
      Is Color of player 1. Immutable
    */
    static
    bool isColor1Immutable()
    {
      return self()->isImmutable( QStringLiteral( "Color1" ) );
    }

    /**
      Get Color of player 2.
    */
    static
    QColor color2()
    {
      return self()->mColor2;
    }

    /**
      Is Color of player 2. Immutable
    */
    static
    bool isColor2Immutable()
    {
      return self()->isImmutable( QStringLiteral( "Color2" ) );
    }

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

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

      if (!self()->isCubeDimImmutable())
        self()->mCubeDim = v;
    }

    /**
      Get Size of the playing field.
    */
    static
    int cubeDim()
    {
      return self()->mCubeDim;
    }

    /**
      Is Size of the playing field. Immutable
    */
    static
    bool isCubeDimImmutable()
    {
      return self()->isImmutable( QStringLiteral( "CubeDim" ) );
    }

    /**
      Set Whether player 1 is played by the computer.
    */
    static
    void setComputerPlayer1( bool v )
    {
      if (!self()->isComputerPlayer1Immutable())
        self()->mComputerPlayer1 = v;
    }

    /**
      Get Whether player 1 is played by the computer.
    */
    static
    bool computerPlayer1()
    {
      return self()->mComputerPlayer1;
    }

    /**
      Is Whether player 1 is played by the computer. Immutable
    */
    static
    bool isComputerPlayer1Immutable()
    {
      return self()->isImmutable( QStringLiteral( "ComputerPlayer1" ) );
    }

    /**
      Set Whether computer player 1 uses Kepler AI.
    */
    static
    void setKepler1( bool v )
    {
      if (!self()->isKepler1Immutable())
        self()->mKepler1 = v;
    }

    /**
      Get Whether computer player 1 uses Kepler AI.
    */
    static
    bool kepler1()
    {
      return self()->mKepler1;
    }

    /**
      Is Whether computer player 1 uses Kepler AI. Immutable
    */
    static
    bool isKepler1Immutable()
    {
      return self()->isImmutable( QStringLiteral( "Kepler1" ) );
    }

    /**
      Set Whether computer player 1 uses Newton AI.
    */
    static
    void setNewton1( bool v )
    {
      if (!self()->isNewton1Immutable())
        self()->mNewton1 = v;
    }

    /**
      Get Whether computer player 1 uses Newton AI.
    */
    static
    bool newton1()
    {
      return self()->mNewton1;
    }

    /**
      Is Whether computer player 1 uses Newton AI. Immutable
    */
    static
    bool isNewton1Immutable()
    {
      return self()->isImmutable( QStringLiteral( "Newton1" ) );
    }

    /**
      Set Skill of computer player 1.
    */
    static
    void setSkill1( int v )
    {
      if (!self()->isSkill1Immutable())
        self()->mSkill1 = v;
    }

    /**
      Get Skill of computer player 1.
    */
    static
    int skill1()
    {
      return self()->mSkill1;
    }

    /**
      Is Skill of computer player 1. Immutable
    */
    static
    bool isSkill1Immutable()
    {
      return self()->isImmutable( QStringLiteral( "Skill1" ) );
    }

    /**
      Set Whether player 2 is played by the computer.
    */
    static
    void setComputerPlayer2( bool v )
    {
      if (!self()->isComputerPlayer2Immutable())
        self()->mComputerPlayer2 = v;
    }

    /**
      Get Whether player 2 is played by the computer.
    */
    static
    bool computerPlayer2()
    {
      return self()->mComputerPlayer2;
    }

    /**
      Is Whether player 2 is played by the computer. Immutable
    */
    static
    bool isComputerPlayer2Immutable()
    {
      return self()->isImmutable( QStringLiteral( "ComputerPlayer2" ) );
    }

    /**
      Set Whether computer player 2 uses Kepler AI.
    */
    static
    void setKepler2( bool v )
    {
      if (!self()->isKepler2Immutable())
        self()->mKepler2 = v;
    }

    /**
      Get Whether computer player 2 uses Kepler AI.
    */
    static
    bool kepler2()
    {
      return self()->mKepler2;
    }

    /**
      Is Whether computer player 2 uses Kepler AI. Immutable
    */
    static
    bool isKepler2Immutable()
    {
      return self()->isImmutable( QStringLiteral( "Kepler2" ) );
    }

    /**
      Set Whether computer player 2 uses Newton AI.
    */
    static
    void setNewton2( bool v )
    {
      if (!self()->isNewton2Immutable())
        self()->mNewton2 = v;
    }

    /**
      Get Whether computer player 2 uses Newton AI.
    */
    static
    bool newton2()
    {
      return self()->mNewton2;
    }

    /**
      Is Whether computer player 2 uses Newton AI. Immutable
    */
    static
    bool isNewton2Immutable()
    {
      return self()->isImmutable( QStringLiteral( "Newton2" ) );
    }

    /**
      Set Skill of computer player 2.
    */
    static
    void setSkill2( int v )
    {
      if (!self()->isSkill2Immutable())
        self()->mSkill2 = v;
    }

    /**
      Get Skill of computer player 2.
    */
    static
    int skill2()
    {
      return self()->mSkill2;
    }

    /**
      Is Skill of computer player 2. Immutable
    */
    static
    bool isSkill2Immutable()
    {
      return self()->isImmutable( QStringLiteral( "Skill2" ) );
    }

    /**
      Set Pause before each computer move.
    */
    static
    void setPauseForComputer( bool v )
    {
      if (!self()->isPauseForComputerImmutable())
        self()->mPauseForComputer = v;
    }

    /**
      Get Pause before each computer move.
    */
    static
    bool pauseForComputer()
    {
      return self()->mPauseForComputer;
    }

    /**
      Is Pause before each computer move. Immutable
    */
    static
    bool isPauseForComputerImmutable()
    {
      return self()->isImmutable( QStringLiteral( "PauseForComputer" ) );
    }

    /**
      Get Pause before each cascade step.
    */
    static
    bool pauseForStep()
    {
      return self()->mPauseForStep;
    }

    /**
      Is Pause before each cascade step. Immutable
    */
    static
    bool isPauseForStepImmutable()
    {
      return self()->isImmutable( QStringLiteral( "PauseForStep" ) );
    }

  protected:
    Prefs();
    friend class PrefsHelper;


    // Game
    int mAnimationSpeed;
    bool mAnimationNone;
    bool mAnimationDelay;
    bool mAnimationBlink;
    bool mAnimationSpread;
    QColor mColor0;
    QColor mColor1;
    QColor mColor2;
    int mCubeDim;
    bool mComputerPlayer1;
    bool mKepler1;
    bool mNewton1;
    int mSkill1;
    bool mComputerPlayer2;
    bool mKepler2;
    bool mNewton2;
    int mSkill2;
    bool mPauseForComputer;
    bool mPauseForStep;
};

#endif

