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

#include "choqokappearancesettings.h"

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

using namespace Choqok;

namespace Choqok {

class AppearanceSettingsHelper
{
  public:
    AppearanceSettingsHelper() : q(0) {}
    ~AppearanceSettingsHelper() { delete q; }
    AppearanceSettings *q;
};
}

Q_GLOBAL_STATIC(AppearanceSettingsHelper, s_globalAppearanceSettings)
AppearanceSettings *AppearanceSettings::self()
{
  if (!s_globalAppearanceSettings()->q) {
    new AppearanceSettings;
    s_globalAppearanceSettings()->q->read();
  }

  return s_globalAppearanceSettings()->q;
}

AppearanceSettings::AppearanceSettings(  )
  : KConfigSkeleton( QStringLiteral( "choqokrc" ) )
{
  Q_ASSERT(!s_globalAppearanceSettings()->q);
  s_globalAppearanceSettings()->q = this;
  setCurrentGroup( QStringLiteral( "Appearance" ) );

  mIsEmoticonsEnabledItem = new KConfigSkeleton::ItemBool( currentGroup(), QStringLiteral( "isEmoticonsEnabled" ), mIsEmoticonsEnabled, true );
  addItem( mIsEmoticonsEnabledItem, QStringLiteral( "isEmoticonsEnabled" ) );
  mIsCustomUiItem = new KConfigSkeleton::ItemBool( currentGroup(), QStringLiteral( "isCustomUi" ), mIsCustomUi, false );
  addItem( mIsCustomUiItem, QStringLiteral( "isCustomUi" ) );
  mReadBackColorItem = new KConfigSkeleton::ItemColor( currentGroup(), QStringLiteral( "readBackColor" ), mReadBackColor, QColor( "white" ) );
  addItem( mReadBackColorItem, QStringLiteral( "readBackColor" ) );
  mUnreadBackColorItem = new KConfigSkeleton::ItemColor( currentGroup(), QStringLiteral( "unreadBackColor" ), mUnreadBackColor, QColor( "yellow" ) );
  addItem( mUnreadBackColorItem, QStringLiteral( "unreadBackColor" ) );
  mOwnBackColorItem = new KConfigSkeleton::ItemColor( currentGroup(), QStringLiteral( "ownBackColor" ), mOwnBackColor, QColor( "white" ) );
  addItem( mOwnBackColorItem, QStringLiteral( "ownBackColor" ) );
  mReadForeColorItem = new KConfigSkeleton::ItemColor( currentGroup(), QStringLiteral( "readForeColor" ), mReadForeColor, QColor( "Black" ) );
  addItem( mReadForeColorItem, QStringLiteral( "readForeColor" ) );
  mUnreadForeColorItem = new KConfigSkeleton::ItemColor( currentGroup(), QStringLiteral( "unreadForeColor" ), mUnreadForeColor, QColor( "Black" ) );
  addItem( mUnreadForeColorItem, QStringLiteral( "unreadForeColor" ) );
  mOwnForeColorItem = new KConfigSkeleton::ItemColor( currentGroup(), QStringLiteral( "ownForeColor" ), mOwnForeColor, QColor( "Black" ) );
  addItem( mOwnForeColorItem, QStringLiteral( "ownForeColor" ) );
  mShowRetweetsInChoqokWayItem = new KConfigSkeleton::ItemBool( currentGroup(), QStringLiteral( "showRetweetsInChoqokWay" ), mShowRetweetsInChoqokWay, false );
  addItem( mShowRetweetsInChoqokWayItem, QStringLiteral( "showRetweetsInChoqokWay" ) );
  mUseReverseOrderItem = new KConfigSkeleton::ItemBool( currentGroup(), QStringLiteral( "useReverseOrder" ), mUseReverseOrder, false );
  addItem( mUseReverseOrderItem, QStringLiteral( "useReverseOrder" ) );
  mFontItem = new KConfigSkeleton::ItemFont( currentGroup(), QStringLiteral( "font" ), mFont, QFont(QLatin1String("DejaVu Sans"), 9) );
  addItem( mFontItem, QStringLiteral( "font" ) );

  setCurrentGroup( QStringLiteral( "TabBar" ) );

  mTabBarPositionItem = new KConfigSkeleton::ItemInt( currentGroup(), QStringLiteral( "TabBarPosition" ), mTabBarPosition, 2 );
  addItem( mTabBarPositionItem, QStringLiteral( "TabBarPosition" ) );
  mTabBarSizeItem = new KConfigSkeleton::ItemInt( currentGroup(), QStringLiteral( "TabBarSize" ), mTabBarSize, 22 );
  addItem( mTabBarSizeItem, QStringLiteral( "TabBarSize" ) );
  mTabBarIsStyledItem = new KConfigSkeleton::ItemBool( currentGroup(), QStringLiteral( "TabBarIsStyled" ), mTabBarIsStyled, true );
  addItem( mTabBarIsStyledItem, QStringLiteral( "TabBarIsStyled" ) );
}

AppearanceSettings::~AppearanceSettings()
{
  s_globalAppearanceSettings()->q = 0;
}

