• Skip to content
  • Skip to link menu
KDE API Reference
  • KDE API Reference
  • kdepim API Reference
  • KDE Home
  • Contact Us
 

kjots

  • sources
  • kde-4.12
  • kdepim
  • kjots
KJotsSettings.cpp
Go to the documentation of this file.
1 // This file is generated by kconfig_compiler from kjots.kcfg.
2 // All changes you do to this file will be lost.
3 
4 #include "KJotsSettings.h"
5 
6 #include <kglobal.h>
7 #include <QtCore/QFile>
8 
9 class KJotsSettingsHelper
10 {
11  public:
12  KJotsSettingsHelper() : q(0) {}
13  ~KJotsSettingsHelper() { delete q; }
14  KJotsSettings *q;
15 };
16 K_GLOBAL_STATIC(KJotsSettingsHelper, s_globalKJotsSettings)
17 KJotsSettings *KJotsSettings::self()
18 {
19  if (!s_globalKJotsSettings->q) {
20  new KJotsSettings;
21  s_globalKJotsSettings->q->readConfig();
22  }
23 
24  return s_globalKJotsSettings->q;
25 }
26 
27 KJotsSettings::KJotsSettings( )
28  : KConfigSkeleton( QLatin1String( "kjotsrc" ) )
29 {
30  Q_ASSERT(!s_globalKJotsSettings->q);
31  s_globalKJotsSettings->q = this;
32  setCurrentGroup( QLatin1String( "kjots" ) );
33 
34  QList<int> defaultSplitterSizes;
35 
36  KConfigSkeleton::ItemIntList *itemSplitterSizes;
37  itemSplitterSizes = new KConfigSkeleton::ItemIntList( currentGroup(), QLatin1String( "SplitterSizes" ), mSplitterSizes, defaultSplitterSizes );
38  addItem( itemSplitterSizes, QLatin1String( "SplitterSizes" ) );
39  KConfigSkeleton::ItemULongLong *itemCurrentSelection;
40  itemCurrentSelection = new KConfigSkeleton::ItemULongLong( currentGroup(), QLatin1String( "CurrentSelection" ), mCurrentSelection );
41  addItem( itemCurrentSelection, QLatin1String( "CurrentSelection" ) );
42  KConfigSkeleton::ItemFont *itemFont;
43  itemFont = new KConfigSkeleton::ItemFont( currentGroup(), QLatin1String( "Font" ), mFont, KGlobalSettings::generalFont() );
44  addItem( itemFont, QLatin1String( "Font" ) );
45  KConfigSkeleton::ItemBool *itemAutoSave;
46  itemAutoSave = new KConfigSkeleton::ItemBool( currentGroup(), QLatin1String( "AutoSave" ), mAutoSave, true );
47  addItem( itemAutoSave, QLatin1String( "AutoSave" ) );
48  KConfigSkeleton::ItemBool *itemUnicode;
49  itemUnicode = new KConfigSkeleton::ItemBool( currentGroup(), QLatin1String( "Unicode" ), mUnicode, false );
50  addItem( itemUnicode, QLatin1String( "Unicode" ) );
51  KConfigSkeleton::ItemInt *itemAutoSaveInterval;
52  itemAutoSaveInterval = new KConfigSkeleton::ItemInt( currentGroup(), QLatin1String( "AutoSaveInterval" ), mAutoSaveInterval, 5 );
53  addItem( itemAutoSaveInterval, QLatin1String( "AutoSaveInterval" ) );
54  KConfigSkeleton::ItemULongLong *itemLastId;
55  itemLastId = new KConfigSkeleton::ItemULongLong( currentGroup(), QLatin1String( "LastId" ), mLastId, 0 );
56  addItem( itemLastId, QLatin1String( "LastId" ) );
57  KConfigSkeleton::ItemString *itemBookshelfOrder;
58  itemBookshelfOrder = new KConfigSkeleton::ItemString( currentGroup(), QLatin1String( "BookshelfOrder" ), mBookshelfOrder );
59  addItem( itemBookshelfOrder, QLatin1String( "BookshelfOrder" ) );
60  KConfigSkeleton::ItemBool *itemPageNamePrompt;
61  itemPageNamePrompt = new KConfigSkeleton::ItemBool( currentGroup(), QLatin1String( "PageNamePrompt" ), mPageNamePrompt, false );
62  addItem( itemPageNamePrompt, QLatin1String( "PageNamePrompt" ) );
63 }
64 
65 KJotsSettings::~KJotsSettings()
66 {
67  if (!s_globalKJotsSettings.isDestroyed()) {
68  s_globalKJotsSettings->q = 0;
69  }
70 }
71 
KJotsSettings::mPageNamePrompt
bool mPageNamePrompt
Definition: KJotsSettings.h:157
KJotsSettings::mBookshelfOrder
QString mBookshelfOrder
Definition: KJotsSettings.h:156
KJotsSettings
Definition: KJotsSettings.h:10
KJotsSettings::mCurrentSelection
quint64 mCurrentSelection
Definition: KJotsSettings.h:150
KJotsSettings::mFont
QFont mFont
Definition: KJotsSettings.h:151
KConfigSkeleton
KJotsSettings::mAutoSave
bool mAutoSave
Definition: KJotsSettings.h:152
KJotsSettings::mUnicode
bool mUnicode
Definition: KJotsSettings.h:153
KJotsSettings::~KJotsSettings
~KJotsSettings()
Definition: KJotsSettings.cpp:65
KJotsSettings::KJotsSettings
KJotsSettings()
Definition: KJotsSettings.cpp:27
KJotsSettings.h
KJotsSettings::mSplitterSizes
QList< int > mSplitterSizes
Definition: KJotsSettings.h:149
KJotsSettings::mLastId
quint64 mLastId
Definition: KJotsSettings.h:155
KJotsSettings::mAutoSaveInterval
int mAutoSaveInterval
Definition: KJotsSettings.h:154
This file is part of the KDE documentation.
Documentation copyright © 1996-2014 The KDE developers.
Generated on Tue Oct 14 2014 22:55:39 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.

kjots

Skip menu "kjots"
  • Main Page
  • Namespace List
  • Alphabetical List
  • Class List
  • Class Hierarchy
  • Class Members
  • File List
  • File Members

kdepim API Reference

Skip menu "kdepim API Reference"
  • akonadi_next
  • akregator
  • blogilo
  • calendarsupport
  • console
  •   kabcclient
  •   konsolekalendar
  • kaddressbook
  • kalarm
  •   lib
  • kdgantt2
  • kjots
  • kleopatra
  • kmail
  • knode
  • knotes
  • kontact
  • korgac
  • korganizer
  • ktimetracker
  • libkdepim
  • libkleo
  • libkpgp
  • mailcommon
  • messagelist
  • messageviewer

Search



Report problems with this website to our bug tracking system.
Contact the specific authors with questions and comments about the page contents.

KDE® and the K Desktop Environment® logo are registered trademarks of KDE e.V. | Legal