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

#include "KonsoleSettings.h"

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

using namespace Konsole;

namespace Konsole {

class KonsoleSettingsHelper
{
  public:
    KonsoleSettingsHelper() noexcept : q(nullptr) {}
    ~KonsoleSettingsHelper() noexcept { delete q; q = nullptr; }
    KonsoleSettingsHelper(const KonsoleSettingsHelper&) = delete;
    KonsoleSettingsHelper& operator=(const KonsoleSettingsHelper&) = delete;
    KonsoleSettings *q;
};

}
Q_GLOBAL_STATIC(KonsoleSettingsHelper, s_globalKonsoleSettings)
KonsoleSettings *KonsoleSettings::self()
{
  if (!s_globalKonsoleSettings()->q) {
    new KonsoleSettings;
    s_globalKonsoleSettings()->q->read();
  }

  return s_globalKonsoleSettings()->q;
}

KonsoleSettings::KonsoleSettings( )
  : KConfigSkeleton( QStringLiteral( "konsolerc" ) )
{
  Q_ASSERT(!s_globalKonsoleSettings()->q);
  s_globalKonsoleSettings()->q = this;
  setCurrentGroup( QStringLiteral( "KonsoleWindow" ) );

  mRemoveWindowTitleBarAndFrameItem = new KConfigSkeleton::ItemBool( currentGroup(), QStringLiteral( "RemoveWindowTitleBarAndFrame" ), mRemoveWindowTitleBarAndFrame, false );
  mRemoveWindowTitleBarAndFrameItem->setLabel( QCoreApplication::translate("KonsoleSettings", "Remove window titlebar and frame") );
  addItem( mRemoveWindowTitleBarAndFrameItem, QStringLiteral( "RemoveWindowTitleBarAndFrame" ) );
  mFocusFollowsMouseItem = new KConfigSkeleton::ItemBool( currentGroup(), QStringLiteral( "FocusFollowsMouse" ), mFocusFollowsMouse, false );
  mFocusFollowsMouseItem->setLabel( QCoreApplication::translate("KonsoleSettings", "Focus terminals when the mouse pointer is moved over them") );
  addItem( mFocusFollowsMouseItem, QStringLiteral( "FocusFollowsMouse" ) );
  mShowWindowTitleOnTitleBarItem = new KConfigSkeleton::ItemBool( currentGroup(), QStringLiteral( "ShowWindowTitleOnTitleBar" ), mShowWindowTitleOnTitleBar, false );
  mShowWindowTitleOnTitleBarItem->setLabel( QCoreApplication::translate("KonsoleSettings", "Show window title on the titlebar") );
  mShowWindowTitleOnTitleBarItem->setToolTip( QCoreApplication::translate("KonsoleSettings", "Show window title set by escape sequence on the titlebar") );
  addItem( mShowWindowTitleOnTitleBarItem, QStringLiteral( "ShowWindowTitleOnTitleBar" ) );
  mAllowMenuAcceleratorsItem = new KConfigSkeleton::ItemBool( currentGroup(), QStringLiteral( "AllowMenuAccelerators" ), mAllowMenuAccelerators, false );
  mAllowMenuAcceleratorsItem->setLabel( QCoreApplication::translate("KonsoleSettings", "Enable menu accelerators") );
  mAllowMenuAcceleratorsItem->setToolTip( QCoreApplication::translate("KonsoleSettings", "Allow users to access top menu through Alt+Key combination") );
  addItem( mAllowMenuAcceleratorsItem, QStringLiteral( "AllowMenuAccelerators" ) );
  mRememberWindowSizeItem = new KConfigSkeleton::ItemBool( currentGroup(), QStringLiteral( "RememberWindowSize" ), mRememberWindowSize, true );
  mRememberWindowSizeItem->setLabel( QCoreApplication::translate("KonsoleSettings", "Use current window size on next startup") );
  mRememberWindowSizeItem->setToolTip( QCoreApplication::translate("KonsoleSettings", "The window size will be saved upon exiting Konsole") );
  addItem( mRememberWindowSizeItem, QStringLiteral( "RememberWindowSize" ) );
  mUseSingleInstanceItem = new KConfigSkeleton::ItemBool( currentGroup(), QStringLiteral( "UseSingleInstance" ), mUseSingleInstance, false );
  mUseSingleInstanceItem->setLabel( QCoreApplication::translate("KonsoleSettings", "Run all Konsole windows in a single process") );
  mUseSingleInstanceItem->setToolTip( QCoreApplication::translate("KonsoleSettings", "When launching Konsole re-use existing process if possible") );
  addItem( mUseSingleInstanceItem, QStringLiteral( "UseSingleInstance" ) );
  mForceNewTabsItem = new KConfigSkeleton::ItemBool( currentGroup(), QStringLiteral( "ForceNewTabs" ), mForceNewTabs, false );
  mForceNewTabsItem->setLabel( QCoreApplication::translate("KonsoleSettings", "Force new tabs") );
  mForceNewTabsItem->setToolTip( QCoreApplication::translate("KonsoleSettings", "When launching Konsole create a new tab instead of creating new windows if possible") );
  addItem( mForceNewTabsItem, QStringLiteral( "ForceNewTabs" ) );
  mShowProgressInTaskBarItem = new KConfigSkeleton::ItemBool( currentGroup(), QStringLiteral( "ShowProgressInTaskBar" ), mShowProgressInTaskBar, true );
  mShowProgressInTaskBarItem->setLabel( QCoreApplication::translate("KonsoleSettings", "Show progress in task bar") );
  mShowProgressInTaskBarItem->setToolTip( QCoreApplication::translate("KonsoleSettings", "When a script reports its progress, it will be shown in the task bar") );
  addItem( mShowProgressInTaskBarItem, QStringLiteral( "ShowProgressInTaskBar" ) );
  mEnableSecuritySensitiveDBusAPIItem = new KConfigSkeleton::ItemBool( currentGroup(), QStringLiteral( "EnableSecuritySensitiveDBusAPI" ), mEnableSecuritySensitiveDBusAPI, false );
  mEnableSecuritySensitiveDBusAPIItem->setLabel( QCoreApplication::translate("KonsoleSettings", "Enable the security sensitive parts of the DBus API") );
  mEnableSecuritySensitiveDBusAPIItem->setToolTip( QCoreApplication::translate("KonsoleSettings", "DBus API like runCommand will be enabled") );
  addItem( mEnableSecuritySensitiveDBusAPIItem, QStringLiteral( "EnableSecuritySensitiveDBusAPI" ) );
  mListenForZModemTerminalCodesItem = new KConfigSkeleton::ItemBool( currentGroup(), QStringLiteral( "ListenForZModemTerminalCodes" ), mListenForZModemTerminalCodes, false );
  mListenForZModemTerminalCodesItem->setLabel( QCoreApplication::translate("KonsoleSettings", "Listen for ZModem Terminal codes") );
  mListenForZModemTerminalCodesItem->setToolTip( QCoreApplication::translate("KonsoleSettings", "Automatic send/receive files over serial connections") );
  addItem( mListenForZModemTerminalCodesItem, QStringLiteral( "ListenForZModemTerminalCodes" ) );

  setCurrentGroup( QStringLiteral( "ThumbnailsSettings" ) );

  mEnableThumbnailsItem = new KConfigSkeleton::ItemBool( currentGroup(), QStringLiteral( "EnableThumbnails" ), mEnableThumbnails, true );
  mEnableThumbnailsItem->setLabel( QCoreApplication::translate("KonsoleSettings", "EnableThumbnails") );
  addItem( mEnableThumbnailsItem, QStringLiteral( "EnableThumbnails" ) );
  mThumbnailSizeItem = new KConfigSkeleton::ItemInt( currentGroup(), QStringLiteral( "ThumbnailSize" ), mThumbnailSize, 250 );
  mThumbnailSizeItem->setLabel( QCoreApplication::translate("KonsoleSettings", "Thumbnail Width") );
  mThumbnailSizeItem->setToolTip( QCoreApplication::translate("KonsoleSettings", "Sets the width of the thumbnail") );
  addItem( mThumbnailSizeItem, QStringLiteral( "ThumbnailSize" ) );
  mThumbnailShiftItem = new KConfigSkeleton::ItemBool( currentGroup(), QStringLiteral( "ThumbnailShift" ), mThumbnailShift, false );
  mThumbnailShiftItem->setLabel( QCoreApplication::translate("KonsoleSettings", "Use Shift to display a thumbnail") );
  mThumbnailShiftItem->setToolTip( QCoreApplication::translate("KonsoleSettings", "Use Shift to display a thumbnail") );
  addItem( mThumbnailShiftItem, QStringLiteral( "ThumbnailShift" ) );
  mThumbnailAltItem = new KConfigSkeleton::ItemBool( currentGroup(), QStringLiteral( "ThumbnailAlt" ), mThumbnailAlt, false );
  mThumbnailAltItem->setLabel( QCoreApplication::translate("KonsoleSettings", "Use Alt to display a thumbnail") );
  mThumbnailAltItem->setToolTip( QCoreApplication::translate("KonsoleSettings", "Use Alt to display a thumbnail") );
  addItem( mThumbnailAltItem, QStringLiteral( "ThumbnailAlt" ) );
  mThumbnailCtrlItem = new KConfigSkeleton::ItemBool( currentGroup(), QStringLiteral( "ThumbnailCtrl" ), mThumbnailCtrl, false );
  mThumbnailCtrlItem->setLabel( QCoreApplication::translate("KonsoleSettings", "Use Ctrl to display a thumbnail") );
  mThumbnailCtrlItem->setToolTip( QCoreApplication::translate("KonsoleSettings", "Use Ctrl to display a thumbnail") );
  addItem( mThumbnailCtrlItem, QStringLiteral( "ThumbnailCtrl" ) );

  setCurrentGroup( QStringLiteral( "SearchSettings" ) );

  mSearchCaseSensitiveItem = new KConfigSkeleton::ItemBool( currentGroup(), QStringLiteral( "SearchCaseSensitive" ), mSearchCaseSensitive, false );
  mSearchCaseSensitiveItem->setLabel( QCoreApplication::translate("KonsoleSettings", "Search is case sensitive") );
  mSearchCaseSensitiveItem->setToolTip( QCoreApplication::translate("KonsoleSettings", "Sets whether the search is case sensitive") );
  addItem( mSearchCaseSensitiveItem, QStringLiteral( "SearchCaseSensitive" ) );
  mSearchRegExpressionItem = new KConfigSkeleton::ItemBool( currentGroup(), QStringLiteral( "SearchRegExpression" ), mSearchRegExpression, false );
  mSearchRegExpressionItem->setLabel( QCoreApplication::translate("KonsoleSettings", "Match using regular expressions") );
  addItem( mSearchRegExpressionItem, QStringLiteral( "SearchRegExpression" ) );
  mSearchHighlightMatchesItem = new KConfigSkeleton::ItemBool( currentGroup(), QStringLiteral( "SearchHighlightMatches" ), mSearchHighlightMatches, true );
  mSearchHighlightMatchesItem->setLabel( QCoreApplication::translate("KonsoleSettings", "Highlight all search matches") );
  mSearchHighlightMatchesItem->setToolTip( QCoreApplication::translate("KonsoleSettings", "Sets whether matching text should be highlighted") );
  addItem( mSearchHighlightMatchesItem, QStringLiteral( "SearchHighlightMatches" ) );
  mSearchReverseSearchItem = new KConfigSkeleton::ItemBool( currentGroup(), QStringLiteral( "SearchReverseSearch" ), mSearchReverseSearch, true );
  mSearchReverseSearchItem->setLabel( QCoreApplication::translate("KonsoleSettings", "Search backwards") );
  mSearchReverseSearchItem->setToolTip( QCoreApplication::translate("KonsoleSettings", "Sets whether search should start from the bottom") );
  addItem( mSearchReverseSearchItem, QStringLiteral( "SearchReverseSearch" ) );
  mSearchNoWrapItem = new KConfigSkeleton::ItemBool( currentGroup(), QStringLiteral( "SearchNoWrap" ), mSearchNoWrap, false );
  mSearchNoWrapItem->setLabel( QCoreApplication::translate("KonsoleSettings", "Search stops instead of wrapping") );
  mSearchNoWrapItem->setToolTip( QCoreApplication::translate("KonsoleSettings", "Sets whether search should stop instead of wrapping") );
  addItem( mSearchNoWrapItem, QStringLiteral( "SearchNoWrap" ) );

  setCurrentGroup( QStringLiteral( "MemorySettings" ) );

  mEnableMemoryMonitoringItem = new KConfigSkeleton::ItemBool( currentGroup(), QStringLiteral( "EnableMemoryMonitoring" ), mEnableMemoryMonitoring, false );
  mEnableMemoryMonitoringItem->setLabel( QCoreApplication::translate("KonsoleSettings", "Control whether child cgroups are created for individual tabs") );
  addItem( mEnableMemoryMonitoringItem, QStringLiteral( "EnableMemoryMonitoring" ) );
  mMemoryLimitValueItem = new KConfigSkeleton::ItemInt( currentGroup(), QStringLiteral( "MemoryLimitValue" ), mMemoryLimitValue, 192 );
  mMemoryLimitValueItem->setLabel( QCoreApplication::translate("KonsoleSettings", "Determines the memory consumption level above which throttling will start") );
  addItem( mMemoryLimitValueItem, QStringLiteral( "MemoryLimitValue" ) );

  setCurrentGroup( QStringLiteral( "SplitView" ) );

  QList<KConfigSkeleton::ItemEnum::Choice> valuesSplitViewVisibility;
  {
    KConfigSkeleton::ItemEnum::Choice choice;
    choice.name = QStringLiteral("AlwaysShowSplitHeader");
    valuesSplitViewVisibility.append( choice );
  }
  {
    KConfigSkeleton::ItemEnum::Choice choice;
    choice.name = QStringLiteral("ShowSplitHeaderWhenNeeded");
    valuesSplitViewVisibility.append( choice );
  }
  {
    KConfigSkeleton::ItemEnum::Choice choice;
    choice.name = QStringLiteral("AlwaysHideSplitHeader");
    valuesSplitViewVisibility.append( choice );
  }
  mSplitViewVisibilityItem = new KConfigSkeleton::ItemEnum( currentGroup(), QStringLiteral( "SplitViewVisibility" ), mSplitViewVisibility, valuesSplitViewVisibility, ShowTabBarWhenNeeded );
  mSplitViewVisibilityItem->setLabel( QCoreApplication::translate("KonsoleSettings", "Control the visibility of the whole tab bar") );
  addItem( mSplitViewVisibilityItem, QStringLiteral( "SplitViewVisibility" ) );
  QList<KConfigSkeleton::ItemEnum::Choice> valuesSplitDragHandleSize;
  {
    KConfigSkeleton::ItemEnum::Choice choice;
    choice.name = QStringLiteral("SplitDragHandleSmall");
    valuesSplitDragHandleSize.append( choice );
  }
  {
    KConfigSkeleton::ItemEnum::Choice choice;
    choice.name = QStringLiteral("SplitDragHandleMedium");
    valuesSplitDragHandleSize.append( choice );
  }
  {
    KConfigSkeleton::ItemEnum::Choice choice;
    choice.name = QStringLiteral("SplitDragHandleLarge");
    valuesSplitDragHandleSize.append( choice );
  }
  mSplitDragHandleSizeItem = new KConfigSkeleton::ItemEnum( currentGroup(), QStringLiteral( "SplitDragHandleSize" ), mSplitDragHandleSize, valuesSplitDragHandleSize, SplitDragHandleSmall );
  mSplitDragHandleSizeItem->setLabel( QCoreApplication::translate("KonsoleSettings", "Control the size of the handle between panels") );
  addItem( mSplitDragHandleSizeItem, QStringLiteral( "SplitDragHandleSize" ) );

  setCurrentGroup( QStringLiteral( "TabBar" ) );

  QList<KConfigSkeleton::ItemEnum::Choice> valuesTabBarVisibility;
  {
    KConfigSkeleton::ItemEnum::Choice choice;
    choice.name = QStringLiteral("AlwaysShowTabBar");
    valuesTabBarVisibility.append( choice );
  }
  {
    KConfigSkeleton::ItemEnum::Choice choice;
    choice.name = QStringLiteral("ShowTabBarWhenNeeded");
    valuesTabBarVisibility.append( choice );
  }
  {
    KConfigSkeleton::ItemEnum::Choice choice;
    choice.name = QStringLiteral("AlwaysHideTabBar");
    valuesTabBarVisibility.append( choice );
  }
  mTabBarVisibilityItem = new KConfigSkeleton::ItemEnum( currentGroup(), QStringLiteral( "TabBarVisibility" ), mTabBarVisibility, valuesTabBarVisibility, ShowTabBarWhenNeeded );
  mTabBarVisibilityItem->setLabel( QCoreApplication::translate("KonsoleSettings", "Control the visibility of the whole tab bar") );
  addItem( mTabBarVisibilityItem, QStringLiteral( "TabBarVisibility" ) );
  QList<KConfigSkeleton::ItemEnum::Choice> valuesTabBarPosition;
  {
    KConfigSkeleton::ItemEnum::Choice choice;
    choice.name = QStringLiteral("Top");
    valuesTabBarPosition.append( choice );
  }
  {
    KConfigSkeleton::ItemEnum::Choice choice;
    choice.name = QStringLiteral("Bottom");
    valuesTabBarPosition.append( choice );
  }
  {
    KConfigSkeleton::ItemEnum::Choice choice;
    choice.name = QStringLiteral("Left");
    valuesTabBarPosition.append( choice );
  }
  {
    KConfigSkeleton::ItemEnum::Choice choice;
    choice.name = QStringLiteral("Right");
    valuesTabBarPosition.append( choice );
  }
  mTabBarPositionItem = new KConfigSkeleton::ItemEnum( currentGroup(), QStringLiteral( "TabBarPosition" ), mTabBarPosition, valuesTabBarPosition, Top );
  mTabBarPositionItem->setLabel( QCoreApplication::translate("KonsoleSettings", "Control the position of the tab bar") );
  addItem( mTabBarPositionItem, QStringLiteral( "TabBarPosition" ) );
  mTabBarStyleSheetItem = new KConfigSkeleton::ItemString( currentGroup(), QStringLiteral( "TabBarStyleSheet" ), mTabBarStyleSheet, QStringLiteral( "QTabBar::tab { min-width: 2em ; max-width: 25em }" ) );
  mTabBarStyleSheetItem->setLabel( QCoreApplication::translate("KonsoleSettings", "Control the visual style of the tab bar") );
  addItem( mTabBarStyleSheetItem, QStringLiteral( "TabBarStyleSheet" ) );
  mTabBarUseUserStyleSheetItem = new KConfigSkeleton::ItemBool( currentGroup(), QStringLiteral( "TabBarUseUserStyleSheet" ), mTabBarUseUserStyleSheet, false );
  mTabBarUseUserStyleSheetItem->setLabel( QCoreApplication::translate("KonsoleSettings", "Use a user-defined .css file for the tab bar") );
  addItem( mTabBarUseUserStyleSheetItem, QStringLiteral( "TabBarUseUserStyleSheet" ) );
  mTabBarUserStyleSheetFileItem = new KConfigSkeleton::ItemUrl( currentGroup(), QStringLiteral( "TabBarUserStyleSheetFile" ), mTabBarUserStyleSheetFile );
  mTabBarUserStyleSheetFileItem->setLabel( QCoreApplication::translate("KonsoleSettings", "The .css file to use for the tab bar style") );
  addItem( mTabBarUserStyleSheetFileItem, QStringLiteral( "TabBarUserStyleSheetFile" ) );
  mCloseTabOnMiddleMouseButtonItem = new KConfigSkeleton::ItemBool( currentGroup(), QStringLiteral( "CloseTabOnMiddleMouseButton" ), mCloseTabOnMiddleMouseButton, false );
  mCloseTabOnMiddleMouseButtonItem->setLabel( QCoreApplication::translate("KonsoleSettings", "Allow middle-clicking on open tabs to close them") );
  addItem( mCloseTabOnMiddleMouseButtonItem, QStringLiteral( "CloseTabOnMiddleMouseButton" ) );
  mNewTabButtonItem = new KConfigSkeleton::ItemBool( currentGroup(), QStringLiteral( "NewTabButton" ), mNewTabButton, false );
  mNewTabButtonItem->setLabel( QCoreApplication::translate("KonsoleSettings", "Control the visibility of 'New Tab' button on the tab bar") );
  addItem( mNewTabButtonItem, QStringLiteral( "NewTabButton" ) );
  QList<KConfigSkeleton::ItemEnum::Choice> valuesSearchTabsButton;
  {
    KConfigSkeleton::ItemEnum::Choice choice;
    choice.name = QStringLiteral("ShowSearchTabsButton");
    valuesSearchTabsButton.append( choice );
  }
  {
    KConfigSkeleton::ItemEnum::Choice choice;
    choice.name = QStringLiteral("HideSearchTabsButton");
    valuesSearchTabsButton.append( choice );
  }
  mSearchTabsButtonItem = new KConfigSkeleton::ItemEnum( currentGroup(), QStringLiteral( "SearchTabsButton" ), mSearchTabsButton, valuesSearchTabsButton, ShowSearchTabsButton );
  mSearchTabsButtonItem->setLabel( QCoreApplication::translate("KonsoleSettings", "Control the visibility of 'Search Tabs' button on the tab bar") );
  addItem( mSearchTabsButtonItem, QStringLiteral( "SearchTabsButton" ) );
  QList<KConfigSkeleton::ItemEnum::Choice> valuesCloseTabButton;
  {
    KConfigSkeleton::ItemEnum::Choice choice;
    choice.name = QStringLiteral("OnEachTab");
    valuesCloseTabButton.append( choice );
  }
  {
    KConfigSkeleton::ItemEnum::Choice choice;
    choice.name = QStringLiteral("OnTabBar");
    valuesCloseTabButton.append( choice );
  }
  {
    KConfigSkeleton::ItemEnum::Choice choice;
    choice.name = QStringLiteral("None");
    valuesCloseTabButton.append( choice );
  }
  mCloseTabButtonItem = new KConfigSkeleton::ItemEnum( currentGroup(), QStringLiteral( "CloseTabButton" ), mCloseTabButton, valuesCloseTabButton, OnEachTab );
  mCloseTabButtonItem->setLabel( QCoreApplication::translate("KonsoleSettings", "Control where the \"Close tab\" button will be displayed") );
  addItem( mCloseTabButtonItem, QStringLiteral( "CloseTabButton" ) );
  QList<KConfigSkeleton::ItemEnum::Choice> valuesNewTabBehavior;
  {
    KConfigSkeleton::ItemEnum::Choice choice;
    choice.name = QStringLiteral("PutNewTabAtTheEnd");
    valuesNewTabBehavior.append( choice );
  }
  {
    KConfigSkeleton::ItemEnum::Choice choice;
    choice.name = QStringLiteral("PutNewTabAfterCurrentTab");
    valuesNewTabBehavior.append( choice );
  }
  mNewTabBehaviorItem = new KConfigSkeleton::ItemEnum( currentGroup(), QStringLiteral( "NewTabBehavior" ), mNewTabBehavior, valuesNewTabBehavior, PutNewTabAtTheEnd );
  mNewTabBehaviorItem->setLabel( QCoreApplication::translate("KonsoleSettings", "Control where to put the new tab") );
  addItem( mNewTabBehaviorItem, QStringLiteral( "NewTabBehavior" ) );
  mExpandTabWidthItem = new KConfigSkeleton::ItemBool( currentGroup(), QStringLiteral( "ExpandTabWidth" ), mExpandTabWidth, false );
  mExpandTabWidthItem->setLabel( QCoreApplication::translate("KonsoleSettings", "Expand the tab widths") );
  addItem( mExpandTabWidthItem, QStringLiteral( "ExpandTabWidth" ) );

  setCurrentGroup( QStringLiteral( "PrintOptions" ) );

  mPrinterFriendlyItem = new KConfigSkeleton::ItemBool( currentGroup(), QStringLiteral( "PrinterFriendly" ), mPrinterFriendly, true );
  mPrinterFriendlyItem->setLabel( QCoreApplication::translate("KonsoleSettings", "Printer &friendly mode (black text, no background)") );
  addItem( mPrinterFriendlyItem, QStringLiteral( "PrinterFriendly" ) );
  mScaleOutputItem = new KConfigSkeleton::ItemBool( currentGroup(), QStringLiteral( "ScaleOutput" ), mScaleOutput, true );
  mScaleOutputItem->setLabel( QCoreApplication::translate("KonsoleSettings", "&Scale output") );
  addItem( mScaleOutputItem, QStringLiteral( "ScaleOutput" ) );

  setCurrentGroup( QStringLiteral( "FileLocation" ) );

  mScrollbackUseSystemLocationItem = new KConfigSkeleton::ItemBool( currentGroup(), QStringLiteral( "scrollbackUseSystemLocation" ), mScrollbackUseSystemLocation, true );
  mScrollbackUseSystemLocationItem->setLabel( QCoreApplication::translate("KonsoleSettings", "For scrollback files, use system-wide folder location") );
  addItem( mScrollbackUseSystemLocationItem, QStringLiteral( "scrollbackUseSystemLocation" ) );
  mScrollbackUseCacheLocationItem = new KConfigSkeleton::ItemBool( currentGroup(), QStringLiteral( "scrollbackUseCacheLocation" ), mScrollbackUseCacheLocation, false );
  mScrollbackUseCacheLocationItem->setLabel( QCoreApplication::translate("KonsoleSettings", "For scrollback files, use user's specific folder location") );
  addItem( mScrollbackUseCacheLocationItem, QStringLiteral( "scrollbackUseCacheLocation" ) );
  mScrollbackUseSpecifiedLocationItem = new KConfigSkeleton::ItemBool( currentGroup(), QStringLiteral( "scrollbackUseSpecifiedLocation" ), mScrollbackUseSpecifiedLocation, false );
  mScrollbackUseSpecifiedLocationItem->setLabel( QCoreApplication::translate("KonsoleSettings", "For scrollback files, use specified folder location") );
  addItem( mScrollbackUseSpecifiedLocationItem, QStringLiteral( "scrollbackUseSpecifiedLocation" ) );
  mScrollbackUseSpecifiedLocationDirectoryItem = new KConfigSkeleton::ItemUrl( currentGroup(), QStringLiteral( "scrollbackUseSpecifiedLocationDirectory" ), mScrollbackUseSpecifiedLocationDirectory );
  mScrollbackUseSpecifiedLocationDirectoryItem->setLabel( QCoreApplication::translate("KonsoleSettings", "For scrollback files, use this folder") );
  addItem( mScrollbackUseSpecifiedLocationDirectoryItem, QStringLiteral( "scrollbackUseSpecifiedLocationDirectory" ) );

  setCurrentGroup( QStringLiteral( "LightDarkTheme" ) );

  mSyncProfileWithSystemThemeItem = new KConfigSkeleton::ItemBool( currentGroup(), QStringLiteral( "SyncProfileWithSystemTheme" ), mSyncProfileWithSystemTheme, false );
  mSyncProfileWithSystemThemeItem->setLabel( QCoreApplication::translate("KonsoleSettings", "Sync profile with system theme") );
  addItem( mSyncProfileWithSystemThemeItem, QStringLiteral( "SyncProfileWithSystemTheme" ) );
  mLightThemeProfileItem = new KConfigSkeleton::ItemString( currentGroup(), QStringLiteral( "LightThemeProfile" ), mLightThemeProfile, QStringLiteral( "_builtin_" ) );
  mLightThemeProfileItem->setLabel( QCoreApplication::translate("KonsoleSettings", "Profile to use for light system theme") );
  addItem( mLightThemeProfileItem, QStringLiteral( "LightThemeProfile" ) );
  mDarkThemeProfileItem = new KConfigSkeleton::ItemString( currentGroup(), QStringLiteral( "DarkThemeProfile" ), mDarkThemeProfile, QStringLiteral( "_builtin_" ) );
  mDarkThemeProfileItem->setLabel( QCoreApplication::translate("KonsoleSettings", "Profile to use for dark system theme") );
  addItem( mDarkThemeProfileItem, QStringLiteral( "DarkThemeProfile" ) );
}

KonsoleSettings::~KonsoleSettings()
{
  if (s_globalKonsoleSettings.exists() && !s_globalKonsoleSettings.isDestroyed()) {
    s_globalKonsoleSettings()->q = nullptr;
  }
}

