3.6 Properties
3.6.1 Nomenclature and format
The names of the variables of the class with which the prefix ' F ' is used are consistent.
3.7 Files
3.7.1 Project Files
3.7.1.1 Project directory Structure
Program Home directory--bin (application path)
-DB (the path where the local database resides)
-doc (the path where the document resides)
-hlp (the path where the Help files are located)
-backup (Backup path)
-tmp (temporary file path)
3.7.1.2 naming
The project file must use a meaningful name. For example: Delphi System Information in the project file is named SYSINFO.DPR.
3.7.2 Form File
3.7.2.1 naming
Consistent with the name of the form: for example, the name of the form is FormMain, and the name of the form file is formmain.frm.
3.7.3 Data Module File
3.7.3.1 naming
The name of the data module file should be meaningful and use ' DM ' as a prefix. For example, the user Data module is named ' Dmcustomers.dfm '.
3.7.4 Remote Data Module file
3.7.4.1 naming
The name of the remote Data module file should be meaningful and use ' RDM ' as the prefix. For example, the user remote Data module is named ' Rdmcustomers.dfm '.
3.7.5 Unit File
3.7.5.1 Common Unit
3.7.5.1.1 Unit file name
The name of the unit file should be meaningful and use ' unit ' as the prefix. For example: The universal unit is named ' Unitgeneral '.
3.7.5.2 Form Units
3.7.5.2.1 naming
The name of the form unit file must be the same as the name of the form. For example: The main form is called Formmain.pas the form unit file is named: Unitformmain.
3.7.5.3 Data Module Unis
3.7.5.3.1 naming
The name of the Data module unit file must be the same as the name of the data module. For example: The main data module called Dmmain.pas the Data Module unit file is named: Unitdmmain.
3.7.5.4 file Header
The head of all files should be written on the purpose of this file, the author, the date and the input and output. For example:
{
Date Modified:
Author:
Use:
This modular structure consists of:
}
3.7.6 forms and Data Modules forms
3.7.6.1 Form Class
1. Form class naming standard
The name of the forms class should be meaningful and use ' tform ' as a prefix. For example: The name of the About Form class is:
Taboutform = Class (Tform)
The name of the main form is
Tmainform = Class (Tform)
2. Naming criteria for form class instances
The name of the class instance of form should be the same as the name of the form class of ' T '. For example:
Type Name
Instance Name
Taboutform
AboutForm
Tmainform
MainForm
Tcustomerentryform
Customerentryform
3.7.6.2 Data Modules Form
3.7.6.2.1. Data Module Form naming standard
The name of the Data Modules forms class should be meaningful and use ' TDM ' as a prefix. For example:
Tdmcustomer = Class (Tdatamodule)
Tdmorders = Class (Tdatamodule)
3.7.6.2.2. Data Module Instance naming standard
The name of the class instance of the data module form should be the same as the name of the Data module form Class of ' T '. For example:
Type Name
Instance Name
Tcustomerdatamodule
Customerdatamodule
Tordersdatamodule
Ordersdatamodule
3.8 Control
3.8.1 the name of the control instance
The instance of the control should be prefixed with the name of the control class that removes ' T ', for example, the name of the Tedit that entered the user's name is: Editusername.
Shorthand for 3.8.2 controls
The name of the control can use the following shorthand, but the drug is added ' _ ' between the name of the control:
3.8.2.1 Standard Tab
MM Tmainmenu
PM Tpopupmenu
MMI Tmainmenuitem
PMI Tpopupmenuitem
LBL Tlabel
EDT Tedit
Mem TMemo
BTN TButton
CB Tcheckbox
RB Tradiobutton
LB Tlistbox
CB Tcombobox
SCB Tscrollbar
GB Tgroupbox
RG Tradiogroup
PNL Tpanel
CL Tcommandlist
3.8.2.2 Additional Tab
BBTN tbitbtn
SB Tspeedbutton
Me Tmaskedit
SG Tstringgrid
DG Tdrawgrid
IMG Timage
SHP Tshape
BVL Tbevel
SBX TScrollBox
CLB Tchecklistbox
SPL Tsplitter
STX Tstatictext
CHT Tchart
3.8.2.3 Win32 Tab
TBC Ttabcontrol
PGC Tpagecontrol
Il timagelist
Re Trichedit
TBR Ttrackbar
PRB Tprogressbar
UD Tupdown
HK Thotkey
Ani Tanimate
DTP Tdatetimepicker
TV Ttreeview
LV TListView
HDR Theadercontrol
STB Tstatusbar
TLB Ttoolbar
CLB Tcoolbar
3.8.2.4 System Tab
TM TTimer
PB Tpaintbox
MP Tmediaplayer
Olec Tolecontainer
DDCC Tddeclientconv
DDCI Tddeclientitem
DDSC Tddeserverconv
Ddsi Tddeserveritem