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

#include <qdebug.h>

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

#include <QFontDatabase>
class Prefs : public KConfigSkeleton
{
  public:
    class EnumTheme
    {
      public:
      enum type { kid, desert, savannah, COUNT };
    };
    class EnumMode
    {
      public:
      enum type { kid, grownup, COUNT };
    };

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

    /**
      Set Language
    */
    static
    void setLanguage( const QString & v )
    {
      if (!self()->isImmutable( QStringLiteral( "Language" ) ))
        self()->mLanguage = v;
    }

    /**
      Get Language
    */
    static
    QString language()
    {
      return self()->mLanguage;
    }

    /**
      Set Theme
    */
    static
    void setTheme( int v )
    {
      if (!self()->isImmutable( QStringLiteral( "Theme" ) ))
        self()->mTheme = v;
    }

    /**
      Get Theme
    */
    static
    int theme()
    {
      return self()->mTheme;
    }

    /**
      Set Whether the menubar is shown or hidden
    */
    static
    void setMenuBarBool( bool v )
    {
      if (!self()->isImmutable( QStringLiteral( "MenuBarBool" ) ))
        self()->mMenuBarBool = v;
    }

    /**
      Get Whether the menubar is shown or hidden
    */
    static
    bool menuBarBool()
    {
      return self()->mMenuBarBool;
    }

    /**
      Set Mode
    */
    static
    void setMode( int v )
    {
      if (!self()->isImmutable( QStringLiteral( "Mode" ) ))
        self()->mMode = v;
    }

    /**
      Get Mode
    */
    static
    int mode()
    {
      return self()->mMode;
    }

    /**
      Set Difficulty level.
    */
    static
    void setLevel( int v )
    {
      if (v < 1)
      {
        qDebug() << "setLevel: value " << v << " is less than the minimum value of 1";
        v = 1;
      }

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

      if (!self()->isImmutable( QStringLiteral( "Level" ) ))
        self()->mLevel = v;
    }

    /**
      Get Difficulty level.
    */
    static
    int level()
    {
      return self()->mLevel;
    }

    /**
      Set Kid Timer
    */
    static
    void setKidTimer( int v )
    {
      if (!self()->isImmutable( QStringLiteral( "KidTimer" ) ))
        self()->mKidTimer = v;
    }

    /**
      Get Kid Timer
    */
    static
    int kidTimer()
    {
      return self()->mKidTimer;
    }

    /**
      Set Grown-up Timer
    */
    static
    void setGrownTimer( int v )
    {
      if (!self()->isImmutable( QStringLiteral( "GrownTimer" ) ))
        self()->mGrownTimer = v;
    }

    /**
      Get Grown-up Timer
    */
    static
    int grownTimer()
    {
      return self()->mGrownTimer;
    }

    /**
      Set Font
    */
    static
    void setFont( const QFont & v )
    {
      if (!self()->isImmutable( QStringLiteral( "Font" ) ))
        self()->mFont = v;
    }

    /**
      Get Font
    */
    static
    QFont font()
    {
      return self()->mFont;
    }

  protected:
    Prefs();
    friend class PrefsHelper;


    // General
    QString mLanguage;
    int mTheme;
    bool mMenuBarBool;
    int mMode;
    int mLevel;
    int mKidTimer;
    int mGrownTimer;

    // mFont
    QFont mFont;

  private:
};

#endif

