Main Page   Class Hierarchy   Alphabetical List   Compound List   File List   Compound Members

FX::FXSettings Class Reference

#include <FXSettings.h>

Inheritance diagram for FX::FXSettings:

FX::FXDict FX::FXObject FX::FXRegistry List of all members.

Public Methods

 FXSettings ()
 Construct settings database.

FXbool parseFile (const FXString &filename, FXbool mark)
 Parse a file containing a settings database.

FXbool unparseFile (const FXString &filename)
 Unparse settings database into given file.

FXStringDictdata (FXuint pos) const
 Obtain the string dictionary for the given section.

FXStringDictfind (const FXchar *section) const
 Find string dictionary for the given section.

FXint readFormatEntry (const FXchar *section, const FXchar *key, const FXchar *fmt,...) FX_SCANF(4
 Read a formatted registry entry, using scanf-style format.

const FXchar * readStringEntry (const FXchar *section, const FXchar *key, const FXchar *def=NULL)
 Read a string registry entry; if no value is found, the default value def is returned.

FXint readIntEntry (const FXchar *section, const FXchar *key, FXint def=0)
 Read a integer registry entry; if no value is found, the default value def is returned.

FXuint readUnsignedEntry (const FXchar *section, const FXchar *key, FXuint def=0)
 Read a unsigned integer registry entry; if no value is found, the default value def is returned.

FXdouble readRealEntry (const FXchar *section, const FXchar *key, FXdouble def=0.0)
 Read a double-precision floating point registry entry; if no value is found, the default value def is returned.

FXColor readColorEntry (const FXchar *section, const FXchar *key, FXColor def=0)
 Read a color value registry entry; if no value is found, the default value def is returned.

FXint writeFormatEntry (const FXchar *section, const FXchar *key, const FXchar *fmt,...) FX_PRINTF(4
 Write a formatted registry entry, using printf-style format.

FXbool writeStringEntry (const FXchar *section, const FXchar *key, const FXchar *val)
 Write a string registry entry.

FXbool writeIntEntry (const FXchar *section, const FXchar *key, FXint val)
 Write a integer registry entry.

FXbool writeUnsignedEntry (const FXchar *section, const FXchar *key, FXuint val)
 Write a unsigned integer registry entry.

FXbool writeRealEntry (const FXchar *section, const FXchar *key, FXdouble val)
 Write a double-precision floating point registry entry.

FXbool writeColorEntry (const FXchar *section, const FXchar *key, FXColor val)
 Write a color value entry.

FXbool deleteEntry (const FXchar *section, const FXchar *key)
 Delete a registry entry.

FXbool existingEntry (const FXchar *section, const FXchar *key)
 See if entry exists.

FXbool deleteSection (const FXchar *section)
 Delete section.

FXbool existingSection (const FXchar *section)
 See if section exists.

FXbool clear ()
 Clear all sections.

void setModified (FXbool mdfy=TRUE)
 Mark as changed.

FXbool isModified () const
 Is it modified.

virtual ~FXSettings ()
 Cleanup.


Detailed Description

FXSettings is a key-value database. This is normally used as part of FXRegistry, but can also be used separately in application that need to maintain a key-value database of their own.