Properties - Source

Top  Previous  Next

The Source tab page lets you decide how source code is treated, and how comments are handled.

 

clip0004

 

The Source tab page

 

Include source code

Mark this checkbox if you want Pascal Browser to include source code in the documentation. This happens if the necessary commands are present in the template files. If they are and this checkbox is not marked, no source code will appear in the documentation. This feature can be handy if you want to hide the source code, but still use your source code enabled templates.

 

Default = Yes

 

Show unused, non-exposed identifiers with special font

Mark this checkbox if you want Pascal Browser to use a special font for identifiers that are not used and not exposed.

 

Default = No

 

Show unused, exposed identifiers with special font

Mark this checkbox if you want Pascal Browser to use a special font for identifiers that are unused and exposed (mentioned in the interface section but only used in the implementation section).

 

If you are generating for a library project, you may want to turn off this option. Otherwise your exposed library routines will be shown as unused.

 

Default = Yes

 

Show used, exposed identifiers with special font

Mark this checkbox if you want Pascal Browser to use a special font for identifiers that are used but exposed (mentioned in the interface section but only used in the implementation section).

 

Default = Yes

 

Show line numbers

Mark this checkbox if you want line numbers in the left margin when source code is included in the documentation.

 

Default = Yes

 

Force first character to uppercase in comments

Mark this checkbox if you want the first character in each comment automatically converted to upper case.

 

Default = Yes

 

 

Example

 

...

type

TMyClass = class // this is my class

end;

...

 

Pascal Browser will present the comment as “This is my class”, if the checkbox is marked.

 

Show comments from include files

Select this option if you want Pascal Browser to also look for comments in include files, if the include directive is in a place where Pascal Browser looks for comments.

 

Default  = Yes

 

Remove these leading characters from comments

Specify leading characters that should be removed from the comments.

 

Default = /@* (the characters “/”, “@” and “*” should be filtered out)

 

 

Example:

 

Consider this code:

 

...

type

// *** database record

TMyRec = record

Key : integer;

Value : longint;

end;

...

 

Pascal Browser will extract the text “database record” if “*” is included in the filter string.

 

Skip comment lines starting with these words

Specify words that cause a comment line to be skipped. The line will be skipped if the comment line starts with any of the specified words. For example if "ENDIF" is such a word all comment lines "// ENDIF" are skipped.

 

Default = (none)

 

Comments over Module

Mark this checkbox if you want Pascal Browser to include comments found above the “unit” keyword in the source code. Blank lines are allowed between the declaration and the comment.

 

Default = Yes

 

Example:

 

Consider this code:

 

// general routines

unit General;

// created for internal use

...

 

Pascal Browser will extract the text “general routines”

 

Comments under Module

Mark this checkbox if you want Pascal Browser to include comments found under the “unit” keyword in the source code. Blank lines are allowed between the declaration and the comment.

 

Default = Yes

 

Example:

 

Consider this code:

 

// general routines

unit General;

// created for internal use

...

 

Pascal Browser will extract the text “created for internal use”

 

Comments over Element

Mark this checkbox if you want Pascal Browser to include comments found above the declaration of the identifier in the source code. Blank lines are allowed between the declaration and the comment.

 

Default = Yes

 

Example:

 

Consider this code:

 

...

type

// forward declaration

TMyClass = class; // my class

// needed

...

 

Pascal Browser will extract the text “forward declaration” if you mark this checkbox. The comment to the right of the declaration (“my class”) will always be extracted.

 

Comments under Element

Mark this checkbox if you want Pascal Browser to include comments found under the declaration of the identifier in the source code. Blank lines are allowed between the declaration and the comment.

 

For subprograms (functions and procedures) when comments are collected from the implementation code, the option is always turned off, regardless of this setting.

 

procedure MyProc;

begin

...

end;

// comments are not collected from this line for MyProc

 

Default = No

 

Example:

 

Consider this code:

 

...

type

 // forward declaration

 TMyClass = class; // my class

 // needed

...

 

Pascal Browser will extract the text “needed” if you mark this checkbox. The comment to the right of the declaration (“my class”) will always be extracted.

 

Comment type

Select if you want to collect comments either as normal, or as XML comments.

 

XML comments are mostly used in .NET code, and normally looks like:

 

/// <summary>

/// This is a summary comment

/// </summary>

 

Unlike in .NET C# and Delphi code, the XML comments do not have to start on lines with three consecutive "/".

Note that you can select XML comment type even if your code is not written for .NET.

 

Default = Normal

 

Comments for subprograms

Select if you want to collect comments for subprograms, from interface or implementation sections, or both.

 

Default = Both

 

 

See also: