// This file is generated by kconfig_compiler_kf5 from infoviewsettings.kcfg.
// All changes you do to this file will be lost.

#include "infoviewsettings.h"

#include <klocalizedstring.h>

#include <qglobal.h>
#include <QtCore/QFile>

using namespace Kasten;

namespace Kasten {

class InfoViewSettingsHelper
{
  public:
    InfoViewSettingsHelper() : q(nullptr) {}
    ~InfoViewSettingsHelper() { delete q; }
    InfoViewSettings *q;
};
}

Q_GLOBAL_STATIC(InfoViewSettingsHelper, s_globalInfoViewSettings)
InfoViewSettings *InfoViewSettings::self()
{
  if (!s_globalInfoViewSettings()->q) {
    new InfoViewSettings;
    s_globalInfoViewSettings()->q->read();
  }

  return s_globalInfoViewSettings()->q;
}

InfoViewSettings::InfoViewSettings(  )
  : KConfigSkeleton()
{
  Q_ASSERT(!s_globalInfoViewSettings()->q);
  s_globalInfoViewSettings()->q = this;
  setCurrentGroup( QStringLiteral( "InfoView" ) );

  QList<int> defaultColumnsWidth;

  KConfigSkeleton::ItemIntList  *itemColumnsWidth;
  itemColumnsWidth = new KConfigSkeleton::ItemIntList( currentGroup(), QStringLiteral( "ColumnsWidth" ), mColumnsWidth, defaultColumnsWidth );
  itemColumnsWidth->setLabel( i18nd("liboktetakasten", "ColumnsWidth") );
  addItem( itemColumnsWidth, QStringLiteral( "ColumnsWidth" ) );
  KConfigSkeleton::ItemString  *itemStyle;
  itemStyle = new KConfigSkeleton::ItemString( currentGroup(), QStringLiteral( "Style" ), mStyle );
  itemStyle->setLabel( i18nd("liboktetakasten", "Style") );
  addItem( itemStyle, QStringLiteral( "Style" ) );
  KConfigSkeleton::ItemString  *itemFixedFont;
  itemFixedFont = new KConfigSkeleton::ItemString( currentGroup(), QStringLiteral( "FixedFont" ), mFixedFont );
  itemFixedFont->setLabel( i18nd("liboktetakasten", "FixedFont") );
  addItem( itemFixedFont, QStringLiteral( "FixedFont" ) );
}

InfoViewSettings::~InfoViewSettings()
{
  s_globalInfoViewSettings()->q = nullptr;
}

