TPJAboutBoxDlg Component


Contents


Description

This component encapsulates an About Box in a non-visual component.

It has string properties to display five different pieces of information in the about box. The positioning and names of the properties are shown in the picture.

The string properties are:

Alternatively, the about box can display information from a VERSIONINFO resource included in the program. This is done by using a TPJVersionInfo component to access the required version information and setting the about box's VersionInfo property to refer to the TPJVersionInfo component. The values of the ProgramName, Version, Copyright and Notes properties are ignored and the information from the TPJVersionInfo component is used instead.

The About box displays an icon. This is the icon defined for the application (see the Icon property of TApplication). If no icon has been specified for the application the default Delphi icon is used. Search for help on the Application tab of the Project Options Dialog Box in Delphi Help for information on specifying an application icon.

The position of the about box on the screen is determined by the DlgLeft and DlgTop properties unless the CentreDlg property is set to True when the about box is positioned at the centre of the screen.

The about box contains a close button, the appearance of which is governed by the ButtonGlyph, ButtonHeight, ButtonWidth, ButtonKind and AutoDetectGlyphs properties. The position of the button is determined by the ButtonPlacing property.

The HelpContext property allows Windows Help to be displayed for the dialog box when F1 is pressed.

The unit name has changed to PJAbout in this release of the code - this means that programs using earlier versions will need to be modified (or to have an alias set in Delphi's Project Options) before being recompiled using the new version.


Compatibility

This component has been tested with Delphi versions 1, 2, 3 and 4 and 6 and is assumed to work correctly in Delphi 5 but this has not been tested.

TPJAboutBoxDlg depends on the TPJVersionInfo component also being installed. The Delphi IDE will not compile the component if TPJVersionInfo is not already installed.

The file PJAbout.pas requires different versions of the TPJVersionInfo component to work with 16 and 32 bit versions of Delphi. 16 and 32 bit versions of TPJVersionInfo can be downloaded from the PJSoft web-site.


Installation

Please ensure that you have installed an appropriate version of TPJVersionInfo before you install this component.

In these instructions $(DELPHI) is to be taken to represent the path where the appropriate version of Delphi was installed. For example, if you have Delphi 2 installed on the default installation path then $(DELPHI) is equivalent to C:\Program Files\Borland\Delphi 2.0.

Installation with Delphi 1

Note that the help file provided does not integrate with the Delphi 1 IDE, but can be accessed independently of the IDE.

  1. Unzip the file PJAbout.zip into a folder, preserving the directory structure.
  2. Copy the files PJAbout.pas and PJAbout.dfm to the folder from where you wish to install the component into the Delphi Component Palette. This will probably be an existing folder where you keep the library components - say the default $(DELPHI)\lib folder.
  3. Copy PJAbout.dcr from the 16 sub-folder into the same place that you copied PJAbout.pas.
  4. Start Delphi. Select the Options | Install Components menu option. Click the Add button, then the Browse button and navigate to the PJAbout.pas file in the directory where you placed it. Click OK to recompile the components library.
  5. You can now delete PJAbout.pas from the place where you copied it if you wish. The component will appear on a palette called PJSoft. You can move the component to a different palette if required.

Installation with Delphi 2

Note that the help file provided does not integrate with the Delphi 1 IDE, but can be accessed independently of the IDE.

  1. Unzip the file PJAbout.zip into a folder, preserving the directory structure.
  2. Copy the files PJAbout.pas and PJAbout.dfm to the folder from where you wish to install the component into the Delphi Component Palette. This will probably be an existing folder where you keep the library components - say the default $(DELPHI)\lib folder.
  3. Copy PJAbout.dcr from the 32 sub-folder into the same place that you copied PJAbout.pas.
  4. Start Delphi. Select the Options | Install Components menu option. Click the Add button, then the Browse button and navigate to the PJAbout.pas file in the folder where you placed it. Click OK to recompile the components library.
  5. You can now delete PJAbout.pas from the place where you copied it if you wish. The component will appear on a palette called PJSoft. You can move the component to a different palette if required.

Installation with Delphi 3 & later

  1. Unzip the file PJAbout.zip into a folder, preserving the directory structure.
  2. Copy the files PJAbout.pas and PJAbout.dfm to the folder from where you wish to install the component into the Delphi Component Palette. This will probably be a sub-folder of the $(DELPHI)\lib folder.
  3. Copy PJAbout.dcr from the 32 sub-folder into the same place that you copied PJAbout.pas.
  4. Install the component into the palette by chosing the Component | Install Component menu option. The following instructions assume you are installing into the default "users components" package:
  5. You can now delete PJAbout.pas from the place where you copied it if you wish. The component will appear on a palette called PJSoft. You can move the component to a different palette if required.
  6. The simplest way to install the help file is to use the PJSoft Component Help Installer Expert, available from my website. To install manually, proceed as follows (replace X is your version of Delphi):


Known Issues


Update History

Un-released
AboutBox v1.0 of 16/02/1998

Un-released
AboutBox v2.0 of 25/04/1998

Un-released
AboutBox v2.1 of 01/08/1998

Un-released
AboutBox v2.2 of 01/08/1998

Un-released
AboutBox v3.0 of 06/12/1998

Release 3.0.1 of 08/07/1999
AboutBox v3.0.1 of 09/04/1999

Release 3.1 of 28/11/1999
AboutBox v3.1 of 27/11/1999

Release 3.2 of 09/03/2002
PJAbout v3.2 of 09/03/2002


License & Disclaimer

This component is copyright © P.D.Johnson, 1998-2002.

The source code and help files can be freely distributed on a not-for-profit basis providing that:

  1. the source code is not altered.
  2. this readme file is distributed with it unchanged

By not-for-profit I mean that you may recover out of pocket expenses incurred in distributing the code, but should not make a profit from this.

If you discover any bugs in this implementation, or if you have any update suggestions, please contact me on peter.johnson@openlink.org.

Please do modify the code for you own use. I'd like to see any changes you make - I could incorporate them into future versions. Please notify me of changes on at the above e-mail address.

This software is provided as is - no warranty is given as to its suitability for any purposes to which you may wish to put it.


About the Author

I'm Peter Johnson - a hobbyist programmer living in Ceredigion in West Wales, UK. I write mainly in Delphi, but occasionally dabble in C, C++ and Java. My programs are available for download on my web-site: http://www.pjsoft.contactbox.co.uk/.

I can be contacted by e-mail on peter.johnson@openlink.org.