[fpc-devel] wrong behaviuor of GetAppConfigDir

Michael Van Canneyt michael at freepascal.org
Wed Feb 4 10:56:57 CET 2009



On Wed, 4 Feb 2009, ik wrote:

> Hello,
> 
> GetAppConfigDir takes the title of the application in order to set the
> directory where the project will store it's configuration.
> 
> This type of behavior is wrong because of:
> 1. Translating of a program (for example for Hebrew in my case) will
> result in different directory
> 2. The title of the application might change depending on things
> inside the program itself.

The title is not used, but the binary name.

> 3. Possible of unsupported chars to be part of the directory name.

To avoid this, set the 'OnGetApplicationName' hook, and provide a name.

So you see, the points you mention were foreseen :-)

Michael.



More information about the fpc-devel mailing list