TConfig Class

Definition

Delphi
type TConfig = class(TObject)
Inheritance
TObject
TConfig

Constants

Constructors

Create

Don't use the constructor, it's used only by the Current() method

Destroy

Don't use the destructor, it's for internal use only

Properties

CustomStyleName

Name of the custom style (by default or customized by the user)

DarkStyleName

Name of the dark style (by default or customized by the user)

Language

The language you should use on screen and messages

LicenseActivationNumber

Activation number, given by the server if the license has been activated.

LicenseDeviceName

The device name used during the license activation. Store it only to check if it's still the current one on your device. (in case the settings have been copied to an other computer)

LicenseEmail

User email, given by the user with its license number when registering the software.

LicenseNumber

License number, given by the user with its email address when registering the software

LightStyleName

Name of the light style (by default or customized by the user)

RecentDocumentsCount

Current number of recent documents

RecentDocumentsMaxCount

Maximum number of recents documents

RecentDocuments[Integer]

Recents documents path

StyleMode

Style mode choosen by the user.

Methods

BeginUpdate

Allow parameters changes but delay the Save operation to the EndUpdate call.

Current

Return the instance to TConfig singleton

EndUpdate(Boolean)

Closes the block of code started with BeginUpdate. If you did some changes, it saves them by default.

GetCustomStyleName
GetDarkStyleName
GetLanguage
GetLicenseActivationNumber
GetLicenseDeviceName
GetLicenseEmail
GetLicenseNumber
GetLightStyleName
GetParams

Use GetParams function in your TConfigHelpers to access global settings storage and add your own parameters.

GetPath

Returns current path of the config file (directory+filename)

GetRecentDocuments(Integer)
GetRecentDocumentsCount
GetRecentDocumentsMaxCount
GetStyleMode
Save

Save current settings.

SetCustomStyleName(string)
SetDarkStyleName(string)
SetLanguage(string)
SetLicenseActivationNumber(string)
SetLicenseDeviceName(string)
SetLicenseEmail(string)
SetLicenseNumber(string)
SetLightStyleName(string)
SetRecentDocuments(Integer, string)
SetRecentDocumentsCount(Integer)
SetRecentDocumentsMaxCount(Integer)
SetStyleMode(TStyleMode)

Fields