kconfigskeleton.cpp
997 KConfigSkeleton::ItemString *KConfigSkeleton::addItemString( const TQString &name, TQString &reference,
1008 KConfigSkeleton::ItemPassword *KConfigSkeleton::addItemPassword( const TQString &name, TQString &reference,
1018 KConfigSkeleton::ItemPath *KConfigSkeleton::addItemPath( const TQString &name, TQString &reference,
1028 KConfigSkeleton::ItemProperty *KConfigSkeleton::addItemProperty( const TQString &name, TQVariant &reference,
1038 KConfigSkeleton::ItemBool *KConfigSkeleton::addItemBool( const TQString &name, bool &reference,
1058 KConfigSkeleton::ItemUInt *KConfigSkeleton::addItemUInt( const TQString &name, unsigned int &reference,
1068 KConfigSkeleton::ItemInt64 *KConfigSkeleton::addItemInt64( const TQString &name, TQ_INT64 &reference,
1078 KConfigSkeleton::ItemUInt64 *KConfigSkeleton::addItemUInt64( const TQString &name, TQ_UINT64 &reference,
1088 KConfigSkeleton::ItemLong *KConfigSkeleton::addItemLong( const TQString &name, long &reference,
1098 KConfigSkeleton::ItemULong *KConfigSkeleton::addItemULong( const TQString &name, unsigned long &reference,
1108 KConfigSkeleton::ItemDouble *KConfigSkeleton::addItemDouble( const TQString &name, double &reference,
1118 KConfigSkeleton::ItemColor *KConfigSkeleton::addItemColor( const TQString &name, TQColor &reference,
1128 KConfigSkeleton::ItemFont *KConfigSkeleton::addItemFont( const TQString &name, TQFont &reference,
1138 KConfigSkeleton::ItemRect *KConfigSkeleton::addItemRect( const TQString &name, TQRect &reference,
1148 KConfigSkeleton::ItemPoint *KConfigSkeleton::addItemPoint( const TQString &name, TQPoint &reference,
1158 KConfigSkeleton::ItemSize *KConfigSkeleton::addItemSize( const TQString &name, TQSize &reference,
1168 KConfigSkeleton::ItemDateTime *KConfigSkeleton::addItemDateTime( const TQString &name, TQDateTime &reference,
1178 KConfigSkeleton::ItemStringList *KConfigSkeleton::addItemStringList( const TQString &name, TQStringList &reference,
1188 KConfigSkeleton::ItemIntList *KConfigSkeleton::addItemIntList( const TQString &name, TQValueList<int> &reference,
TQColor readColorEntry(const TQString &pKey, const TQColor *pDefault=0L) const
Reads a TQColor entry.
Definition: kconfigbase.cpp:970
virtual void usrUseDefaults(bool)
Implemented by subclasses that use special defaults.
Definition: kconfigskeleton.h:1193
TQPoint readPointEntry(const TQString &pKey, const TQPoint *pDefault=0L) const
Reads a TQPoint entry.
Definition: kconfigbase.cpp:919
TQVariant maxValue() const
Return maximum value of item or invalid if not specified.
Definition: kconfigskeleton.cpp:604
ItemPath * addItemPath(const TQString &name, TQString &reference, const TQString &defaultValue=TQString::fromLatin1(""), const TQString &key=TQString::null)
Register a path item of type TQString.
Definition: kconfigskeleton.cpp:1018
ItemSize * addItemSize(const TQString &name, TQSize &reference, const TQSize &defaultValue=TQSize(), const TQString &key=TQString::null)
Register an item of type TQSize.
Definition: kconfigskeleton.cpp:1158
TQVariant minValue() const
Return minimum value of item or invalid if not specified.
Definition: kconfigskeleton.cpp:540
void readConfig(KConfig *config)
This function is called by KConfigSkeleton to read the value for this setting from a config file...
Definition: kconfigskeleton.cpp:793
bool hasKey(const TQString &key) const
Checks whether the key has an entry in the currently active group.
Definition: kconfigbase.cpp:110
bool hasDefault(const TQString &key) const
Returns whether a default is specified for an entry in either the system wide configuration file or t...
Definition: kconfigbase.cpp:1842
void readConfig(KConfig *config)
This function is called by KConfigSkeleton to read the value for this setting from a config file...
Definition: kconfigskeleton.cpp:857
Class for handling a TQRect preferences item.
Definition: kconfigskeleton.h:684
Class for handling an integer preferences item.
Definition: kconfigskeleton.h:447
KConfig * config() const
Return the KConfig object used for reading and writing the settings.
Definition: kconfigskeleton.cpp:918
Class for handling an unsigned long integer preferences item.
Definition: kconfigskeleton.h:576
TQFont readFontEntry(const TQString &pKey, const TQFont *pDefault=0L) const
Reads a TQFont value.
Definition: kconfigbase.cpp:798
void readConfig(KConfig *config)
This function is called by KConfigSkeleton to read the value for this setting from a config file...
Definition: kconfigskeleton.cpp:67
bool entryIsImmutable(const TQString &key) const
Checks whether it is possible to change the given entry.
Definition: kconfigbase.cpp:183
ItemInt * addItemInt(const TQString &name, int &reference, int defaultValue=0, const TQString &key=TQString::null)
Register an item of type int.
Definition: kconfigskeleton.cpp:1048
static TQString obscure(const TQString &str)
Obscure string by using a simple symmetric encryption.
Definition: kstringhandler.cpp:556
void readConfig(KConfig *config)
This function is called by KConfigSkeleton to read the value for this setting from a config file...
Definition: kconfigskeleton.cpp:232
void readConfig(KConfig *config)
This function is called by KConfigSkeleton to read the value for this setting from a config file...
Definition: kconfigskeleton.cpp:574
void writeConfig(KConfig *config)
This function is called by KConfigSkeleton to write the value of this setting to a config file...
Definition: kconfigskeleton.cpp:50
ItemLong * addItemLong(const TQString &name, long &reference, long defaultValue=0, const TQString &key=TQString::null)
Register an item of type long.
Definition: kconfigskeleton.cpp:1088
bool readBoolEntry(const TQString &pKey, bool bDefault=false) const
Reads a boolean entry.
Definition: kconfigbase.cpp:771
void readConfig(KConfig *config)
This function is called by KConfigSkeleton to read the value for this setting from a config file...
Definition: kconfigskeleton.cpp:739
TQVariant maxValue() const
Return maximum value of item or invalid if not specified.
Definition: kconfigskeleton.cpp:489
bool isImmutable(const TQString &name)
Return whether a certain item is immutable.
Definition: kconfigskeleton.cpp:1198
void writeEntry(const TQString &pKey, const TQString &pValue, bool bPersistent=true, bool bGlobal=false, bool bNLS=false)
Writes a key/value pair.
Definition: kconfigbase.cpp:1067
void setDefaults()
Set all registered items to their default values.
Definition: kconfigskeleton.cpp:939
TQVariant maxValue() const
Return maximum value of item or invalid if not specified.
Definition: kconfigskeleton.cpp:262
void readConfig(KConfig *config)
This function is called by KConfigSkeleton to read the value for this setting from a config file...
Definition: kconfigskeleton.cpp:823
ItemPassword * addItemPassword(const TQString &name, TQString &reference, const TQString &defaultValue=TQString::fromLatin1(""), const TQString &key=TQString::null)
Register a password item of type TQString.
Definition: kconfigskeleton.cpp:1008
Class for handling a TQVariant preferences item.
Definition: kconfigskeleton.h:417
void addItem(KConfigSkeletonItem *, const TQString &name=TQString::null)
Register a custom KConfigSkeletonItem with a given name.
Definition: kconfigskeleton.cpp:988
virtual void sync()
Flushes all changes that currently reside only in memory back to disk / permanent storage...
Definition: kconfigbase.cpp:1776
unsigned int readUnsignedNumEntry(const TQString &pKey, unsigned int nDefault=0) const
Reads an unsigned numerical value.
Definition: kconfigbase.cpp:657
Class for handling unsigned 64-bit integer preferences item.
Definition: kconfigskeleton.h:601
void readConfig(KConfig *config)
This function is called by KConfigSkeleton to read the value for this setting from a config file...
Definition: kconfigskeleton.cpp:289
void setGroup(const TQString &group)
Specifies the group in which keys will be read and written.
Definition: kconfigbase.cpp:80
TQVariant minValue() const
Return minimum value of item or invalid if not specified.
Definition: kconfigskeleton.cpp:426
void readConfig(KConfig *config)
This function is called by KConfigSkeleton to read the value for this setting from a config file...
Definition: kconfigskeleton.cpp:459
Class for handling a bool preferences item.
Definition: kconfigskeleton.h:432
void readConfig(KConfig *config)
This function is called by KConfigSkeleton to read the value for this setting from a config file...
Definition: kconfigskeleton.cpp:148
int readNumEntry(const TQString &pKey, int nDefault=0) const
Reads a numerical value.
Definition: kconfigbase.cpp:636
void readConfig(KConfig *config)
This function is called by KConfigSkeleton to read the value for this setting from a config file...
Definition: kconfigskeleton.cpp:175
Class for handling a string list preferences item.
Definition: kconfigskeleton.h:745
Class for handling a font preferences item.
Definition: kconfigskeleton.h:669
virtual void readConfig(KConfig *)=0
This function is called by KConfigSkeleton to read the value for this setting from a config file...
KConfigSkeletonItem * findItem(const TQString &name)
Lookup item by name.
Definition: kconfigskeleton.cpp:1204
void writeConfig(KConfig *config)
This function is called by KConfigSkeleton to write the value of this setting to a config file...
Definition: kconfigskeleton.cpp:318
TQSize readSizeEntry(const TQString &pKey, const TQSize *pDefault=0L) const
Reads a TQSize entry.
Definition: kconfigbase.cpp:944
void readImmutability(KConfig *config)
sets mIsImmutable to true if mKey in config is immutable
Definition: kconfigskeleton.cpp:35
virtual void usrWriteConfig()
Implemented by subclasses that write special config values.
Definition: kconfigskeleton.h:1211
Class for handling an 64-bit integer preferences item.
Definition: kconfigskeleton.h:472
Class for handling a password preferences item.
Definition: kconfigskeleton.h:394
TQVariant minValue() const
Return minimum value of item or invalid if not specified.
Definition: kconfigskeleton.cpp:482
Class for handling a path preferences item.
Definition: kconfigskeleton.h:405
Class for handling a TQPoint preferences item.
Definition: kconfigskeleton.h:699
void setCurrentGroup(const TQString &group)
Set the config file group for subsequent addItem() calls.
Definition: kconfigskeleton.cpp:913
ItemDouble * addItemDouble(const TQString &name, double &reference, double defaultValue=0.0, const TQString &key=TQString::null)
Register an item of type double.
Definition: kconfigskeleton.cpp:1108
TQVariant minValue() const
Return minimum value of item or invalid if not specified.
Definition: kconfigskeleton.cpp:198
Class for hanlding a long integer preferences item.
Definition: kconfigskeleton.h:550
ItemInt64 * addItemInt64(const TQString &name, TQ_INT64 &reference, TQ_INT64 defaultValue=0, const TQString &key=TQString::null)
Register an item of type TQ_INT64.
Definition: kconfigskeleton.cpp:1068
ItemULong * addItemULong(const TQString &name, unsigned long &reference, unsigned long defaultValue=0, const TQString &key=TQString::null)
Register an item of type unsigned long.
Definition: kconfigskeleton.cpp:1098
void readConfig(KConfig *config)
This function is called by KConfigSkeleton to read the value for this setting from a config file...
Definition: kconfigskeleton.cpp:123
ItemDateTime * addItemDateTime(const TQString &name, TQDateTime &reference, const TQDateTime &defaultValue=TQDateTime(), const TQString &key=TQString::null)
Register an item of type TQDateTime.
Definition: kconfigskeleton.cpp:1168
ItemColor * addItemColor(const TQString &name, TQColor &reference, const TQColor &defaultValue=TQColor(128, 128, 128), const TQString &key=TQString::null)
Register an item of type TQColor.
Definition: kconfigskeleton.cpp:1118
void readConfig(KConfig *config)
This function is called by KConfigSkeleton to read the value for this setting from a config file...
Definition: kconfigskeleton.cpp:346
TQValueList< int > readIntListEntry(const TQString &pKey) const
Reads a list of Integers.
Definition: kconfigbase.cpp:590
bool useDefaults(bool b)
Indicate whether this object should reflect the actual values or the default values.
Definition: kconfigskeleton.cpp:923
TQVariant minValue() const
Return minimum value of item or invalid if not specified.
Definition: kconfigskeleton.cpp:255
ItemPoint * addItemPoint(const TQString &name, TQPoint &reference, const TQPoint &defaultValue=TQPoint(), const TQString &key=TQString::null)
Register an item of type TQPoint.
Definition: kconfigskeleton.cpp:1148
ItemUInt64 * addItemUInt64(const TQString &name, TQ_UINT64 &reference, TQ_UINT64 defaultValue=0, const TQString &key=TQString::null)
Register an item of type TQ_UINT64.
Definition: kconfigskeleton.cpp:1078
void readConfig(KConfig *config)
This function is called by KConfigSkeleton to read the value for this setting from a config file...
Definition: kconfigskeleton.cpp:658
ItemStringList * addItemStringList(const TQString &name, TQStringList &reference, const TQStringList &defaultValue=TQStringList(), const TQString &key=TQString::null)
Register an item of type TQStringList.
Definition: kconfigskeleton.cpp:1178
void readConfig(KConfig *config)
This function is called by KConfigSkeleton to read the value for this setting from a config file...
Definition: kconfigskeleton.cpp:517
Class for handling a floating point preference item.
Definition: kconfigskeleton.h:627
unsigned long readUnsignedLongNumEntry(const TQString &pKey, unsigned long nDefault=0) const
Read an unsigned numerical value.
Definition: kconfigbase.cpp:695
TQ_INT64 readNum64Entry(const TQString &pKey, TQ_INT64 nDefault=0) const
Reads a 64-bit numerical value.
Definition: kconfigbase.cpp:713
void writeConfig(KConfig *config)
This function is called by KConfigSkeleton to write the value of this setting to a config file...
Definition: kconfigskeleton.cpp:835
ItemRect * addItemRect(const TQString &name, TQRect &reference, const TQRect &defaultValue=TQRect(), const TQString &key=TQString::null)
Register an item of type TQRect.
Definition: kconfigskeleton.cpp:1138
TQString readEntry(const TQString &pKey, const TQString &aDefault=TQString::null) const
Reads the value of an entry specified by pKey in the current group.
Definition: kconfigbase.cpp:222
void readConfig(KConfig *config)
This function is called by KConfigSkeleton to read the value for this setting from a config file...
Definition: kconfigskeleton.cpp:631
TQ_UINT64 readUnsignedNum64Entry(const TQString &pKey, TQ_UINT64 nDefault=0) const
Read an 64-bit unsigned numerical value.
Definition: kconfigbase.cpp:733
Class for handling an unsingend integer preferences item.
Definition: kconfigskeleton.h:524
ItemIntList * addItemIntList(const TQString &name, TQValueList< int > &reference, const TQValueList< int > &defaultValue=TQValueList< int >(), const TQString &key=TQString::null)
Register an item of type TQValueList<int>.
Definition: kconfigskeleton.cpp:1188
Class for handling a TQSize preferences item.
Definition: kconfigskeleton.h:714
double readDoubleNumEntry(const TQString &pKey, double nDefault=0.0) const
Reads a floating point value.
Definition: kconfigbase.cpp:752
TQRect readRectEntry(const TQString &pKey, const TQRect *pDefault=0L) const
Reads a TQRect entry.
Definition: kconfigbase.cpp:895
void readConfig(KConfig *config)
This function is called by KConfigSkeleton to read the value for this setting from a config file...
Definition: kconfigskeleton.cpp:712
virtual void reparseConfiguration()
Clears all internal data structures and then reread configuration information from disk...
Definition: kconfig.cpp:161
TQStringList readPathListEntry(const TQString &pKey, char sep=',') const
Reads a list of string paths.
Definition: kconfigbase.cpp:622
Class for handling a color preferences item.
Definition: kconfigskeleton.h:653
KConfigSkeleton(const TQString &configname=TQString::null)
Constructor.
Definition: kconfigskeleton.cpp:881
TQVariant minValue() const
Return minimum value of item or invalid if not specified.
Definition: kconfigskeleton.cpp:597
TQString readPathEntry(const TQString &pKey, const TQString &aDefault=TQString::null) const
Reads a path.
Definition: kconfigbase.cpp:608
TQVariant minValue() const
Return minimum value of item or invalid if not specified.
Definition: kconfigskeleton.cpp:369
void writePathEntry(const TQString &pKey, const TQString &path, bool bPersistent=true, bool bGlobal=false, bool bNLS=false)
Writes a file path.
Definition: kconfigbase.cpp:1116
TQVariant maxValue() const
Return maximum value of item or invalid if not specified.
Definition: kconfigskeleton.cpp:547
long readLongNumEntry(const TQString &pKey, long nDefault=0) const
Reads a numerical value.
Definition: kconfigbase.cpp:676
TQVariant maxValue() const
Return maximum value of item or invalid if not specified.
Definition: kconfigskeleton.cpp:376
TQVariant readPropertyEntry(const TQString &pKey, TQVariant::Type) const
Reads the value of an entry specified by pKey in the current group.
Definition: kconfigbase.cpp:366
virtual void usrReadConfig()
Implemented by subclasses that read special config values.
Definition: kconfigskeleton.h:1204
Class for handling a string preferences item.
Definition: kconfigskeleton.h:372
ItemUInt * addItemUInt(const TQString &name, unsigned int &reference, unsigned int defaultValue=0, const TQString &key=TQString::null)
Register an item of type unsigned int.
Definition: kconfigskeleton.cpp:1058
int readListEntry(const TQString &pKey, TQStrList &list, char sep=',') const
Reads a list of strings.
Definition: kconfigbase.cpp:490
void revertToDefault(const TQString &key)
Reverts the entry with key key in the current group in the application specific config file to either...
Definition: kconfigbase.cpp:1815
void readConfig(KConfig *config)
This function is called by KConfigSkeleton to read the value for this setting from a config file...
Definition: kconfigskeleton.cpp:403
TQVariant maxValue() const
Return maximum value of item or invalid if not specified.
Definition: kconfigskeleton.cpp:205
void readConfig(KConfig *config)
This function is called by KConfigSkeleton to read the value for this setting from a config file...
Definition: kconfigskeleton.cpp:766
Class for handling an integer list preferences item.
Definition: kconfigskeleton.h:776
void readConfig(KConfig *config)
This function is called by KConfigSkeleton to read the value for this setting from a config file...
Definition: kconfigskeleton.cpp:685
TQDateTime readDateTimeEntry(const TQString &pKey, const TQDateTime *pDefault=0L) const
Reads a TQDateTime entry.
Definition: kconfigbase.cpp:1035
TQVariant maxValue() const
Return maximum value of item or invalid if not specified.
Definition: kconfigskeleton.cpp:433
ItemString * addItemString(const TQString &name, TQString &reference, const TQString &defaultValue=TQString::fromLatin1(""), const TQString &key=TQString::null)
Register an item of type TQString.
Definition: kconfigskeleton.cpp:997
ItemBool * addItemBool(const TQString &name, bool &reference, bool defaultValue=false, const TQString &key=TQString::null)
Register an item of type bool.
Definition: kconfigskeleton.cpp:1038
Class for handling a TQDateTime preferences item.
Definition: kconfigskeleton.h:729
TQString group() const
Returns the name of the group in which we are searching for keys and from which we are retrieving ent...
Definition: kconfigbase.cpp:101
ItemFont * addItemFont(const TQString &name, TQFont &reference, const TQFont &defaultValue=KGlobalSettings::generalFont(), const TQString &key=TQString::null)
Register an item of type TQFont.
Definition: kconfigskeleton.cpp:1128
ItemProperty * addItemProperty(const TQString &name, TQVariant &reference, const TQVariant &defaultValue=TQVariant(), const TQString &key=TQString::null)
Register a property item of type TQVariant.
Definition: kconfigskeleton.cpp:1028