When declaring classes and so on, what does the "T" in TObject
stand for? Template?
Example:
procedure TfrmMain.CaptureInfo1Click(Sender: TObject);
begin
frmCapture.Show;
end;
When declaring classes and so on, what does the "T" in TObject
stand for? Template?
Example:
procedure TfrmMain.CaptureInfo1Click(Sender: TObject);
begin
frmCapture.Show;
end;
Delphi has a number of officially sanctioned prefixes.
These are all by Borland convention and are not enforced by the compiler.
Prefix | Used for | Notes -------+----------+--------------------------------------------- T | types | Denotes a structured type, class or record I |interfaces| For interfaces, e.g. IInterface F | Field | Private Field in a class or record xx | enum | Enumeration members have a 2 char prefix | | e.g. fsBold, fsItalic for the TFontStyle enum A | params | deprecated ! All method params at one point started with an `A`. this convention is no longer encouraged. Note that the capitalization is as shown.
The reason Delphi uses prefixes is that the language is not case sensitive, so the C/Java trick of using ALLCAPS for constants and Leading caps for types does not work.
All this and more is outlined in the Object Pascal Style Guide, more specifically the section Naming Convention.
It's the style that all source code written by Borland et al follow