PreviousDevelopment Environment Menu System Data File EditorNext

Chapter 3: COBOL Source Information

This chapter describes COBOL Source Information (CSI).

3.1 Introduction

CSI provides an enhanced view of your program when you are editing or testing it. Extensive query facilities enable you to focus on particular pieces of information which can improve your program construction and speed up the debugging process.

Information about particular program features can improve your understanding and navigation of the source code while you are editing it. This type of information can also speed up the debugging process during program animation. COBOL Source Information (CSI), accessed from the Editor and Animator, can provide information on many program features including:

The information is presented both as highlighting and tagging of the source code itself and as a report window containing information about particular features of the program. The information can also be printed.

CSI uses information created when you check the syntax of your program. The Compiler directive CSI directs the Compiler to produce this additional information during the syntax-check phase. This information is stored in the .idy file. The CSI directive is set in the default function key Server Express menus, so that the information is always available.

CSI can provide you with additional warning messages when you check your programs, for example, if your program has overlapping PERFORM THRU ranges. These messages are issued only if you check your programs with the WARNING "2" or WARNING "3" directive.

CSI makes extensive use of toggles to determine the type of information you want to see, and the way it appears on your screen. Most toggle settings can be configured using the standard configuration file mfcobolrc so that you can optimize the behavior of CSI for the way you work.

3.2 Invoking CSI

CSI can be started from the Animator or the Editor. You can either directly enter CSI and start using the CSI menus, or you can enter and perform a query at the same time, by passing a name to be queried. See the section Query Information later in this chapter to see what sort of names can be passed.

3.2.1 Animator

The keys used to invoke CSI are located on the More menu:

F3=CSI Passes or returns you to CSI, located at the current Animator line. If this is the first use of CSI on the current program, no query is active; otherwise you return with your previous settings active.
F5=CSI-enter-name Enables you to enter a name to be queried. If any information is found, you enter CSI.
F6=CSI-word-at-cursor Queries the name at the cursor position. If any information is found, you enter CSI.

3.2.2 Editor

The keys used to invoke CSI are located on the F2=COBOL menu:

F4=return-CSI Returns to CSI in the same state you were in. If this is the first use of CSI, no query is active.
F5=CSI-enter Enables you to enter a name to be queried. If any information is found, you enter CSI.
F6=CSI-at-cursor Queries the name at the cursor position. If any information is found, you enter CSI.

3.2.3 Important Considerations

You should be aware of the following when using CSI:

3.3 The CSI Display

The exact information returned by a query depends not only on the subject of the query, but also on the state of several toggles which enable either extra information to be included, or extraneous information removed. The settings of these toggles can be altered by using the Options function (see the section Functions, Menus, and Toggles later in this chapter).

After performing a query, you are informed of the number of source lines highlighted by the query, and how many were filtered due to the various toggle settings in force.

CSI provides information about an item which you select. The target of a CSI query might be a procedure-name, a called subprogram, a data item or a special reserved name. The target can be selected using the cursor, or entered directly.

3.3.1 How is the Information Displayed?

The results of a query are displayed in two ways:

For example, if you query a paragraph-name, the report window might tell you the procedures which perform it, and the source listing would show those lines which contain the relevant PERFORM statements highlighted.

The main panel of the CSI display shows the source listing of your program. Optionally displayed on top of this is the report window, which provides textual information about the item you have queried. The divider line shows which item you are currently querying, together with the settings of some of the more commonly used toggles.

Either the report window or the source can be active. When the source is active, a cursor is displayed at the current line. When the report window is active, the current line is highlighted (no cursor is displayed). You can change focus between the two panels by pressing W to invoke the Window function (see the section Functions, Menus, and Toggles later in this chapter).

3.3.2 The Report Window

The report window displays the textual information of a query. It is sized and aligned automatically. An indicator in the right border shows what proportion of the available text is displayed in the window.

3.3.3 The Source Listing

The main area of the screen displays the program source listing. Lines related to the query are highlighted and the type of occurrence is also marked in columns 72 through 80. The types of occurrence are as follows:

Use Use of data item
Mod Modification of data item
Defn Definition of procedure/data item
Qual Data item used as qualification
Exec Queried procedure executes a procedure from this line
Efrom Queried procedure is executed from this line
Copy Start of copyfile
Endcpy End of copyfile
Test Value of data item is tested on this line

Sequence numbers and tag indicators can be displayed in columns 1 through 6, and comment lines can be displayed in a different color.

3.3.4 Cursor Control

The current line and cursor can be moved using the following keys:

Key
Function
<up-arrow> Up 1 line
<down-arrow> Down 1 line
Page Up Up 1 page
Page Down Down 1 page
Ctrl+Page Up Up 200 lines
Ctrl+Page Down Down 200 lines
Home source: Moves cursor to beginning of line on first press, and to top of page on second press
report: Moves to top of page
End source: Moves cursor to end of line on first press, and to bottom of page on second press
report: Moves to bottom of page
Ctrl+Home To top of source/text
Ctrl+End To end of source/text
Ctrl+<left-arrow> Scrolls window up one line
Ctrl+<right-arrow> Scrolls window down one line

These keys can be used only when the source window is active:

Key
Function
<left-arrow> Move cursor 1 column left
<right-arrow> Move cursor 1 column right
F9 Move cursor one word left
F10 Move cursor one word right

3.4 Query Information

The following basic types of query are available:

This section describes the information provided by each type of query. Many options are available to restrict or extend the query information. These can be set using toggles or directly at the query-enter prompt. The first three types of query can be selected using the cursor position; the others can be specified only at an enter prompt.

3.4.1 Procedures (Paragraphs and Sections)

The information provided for a procedure consists of:

Name Name of the procedure.
Type Paragraph or section, followed by the segment overlay number if the program is segmented and the procedure is not in the root overlay.
Executed from Lists the procedures and programs from which this procedure item is executed and the type of COBOL statement used to reference it (GO TO, PERFORM, and so on). The source lines containing the relevant statements are highlighted, and marked as "EFrom" (executed-from). The inclusion of this list is toggled on and off by the Executed-from toggle (see the description of the Exec-from function in the section Functions, Menus, and Toggles later in this chapter).
Executes Lists the procedures and subprograms executed from the procedure-name queried, and the type of COBOL statement involved (such as CALL or PERFORM). The corresponding source lines are highlighted. The inclusion of this list is toggled on and off by the Executes toggle (see the description of the Executes function in the section Functions, Menus, and Toggles later in this chapter).
Procedure Data Lists the data items used, modified and tested by the queried procedure, and, depending on the setting of Perform-level (see the description of the Options function), those items modified many levels of PERFORM below the queried procedure. The inclusion of this list is toggled on and off by the Procedure-data toggle (see the description of the Options function later in this chapter).

The results of querying a procedure also depend upon the settings of the Paragraphs, Performs, Go-tos, and Calls toggles (see the description of the Options function later in this chapter).

3.4.2 Called Subprograms

The text information for called subprograms consists of:

Name /number Identifies the subprogram.
Type Call-by-name, call-by-number (to a library routine), or to a data item. The program-name corresponding to a data item can be determined only at run time.
Executed from Lists the procedures which CALL/CHAIN this subprogram, and highlights the source lines containing the relevant statements. You can toggle this list on and off using the Exec-from toggle.

The results of querying a subprogram also depend upon the settings of the Paragraphs and Calls toggles (see the description of the Options function later in this chapter).

3.4.3 Data Items

The term data item, as used here, includes data-names, conditions (level-88 items), constants (level-78 items) and files. The following basic information is provided for each type:

Type The type of data item.
Number of references The number of references to this data item that have been located in the source.
Usage Indication A letter follows the number of references, as follows:
d The data item has no references in the Procedure Division
u The data item is referenced in the Procedure Division, but none of these references causes modification of the item
m The data item has references in the Procedure Division that cause modification.
Related items The data items related to the target data item are listed, if the Related-data toggle is on (see the description of the Options function later in this chapter).
Occurrences All source lines containing occurrences of the data items listed are highlighted. The Data-selector toggle (see the description of the Options function later in this chapter) enables you to specify that only certain types of occurrence of the data items are highlighted.

The following types of data item have additional information:

3.4.3.1 More Complex Options

From Query-enter prompts it is possible to specify more complex options. When querying a data item from a Query-enter prompt it is possible to restrict the occurrences highlighted to certain types of COBOL verb and/or to a range of lines or procedures. Figure 3-1 shows the syntax.



Figure 3-1: Syntax for Search Restriction

Examples:
A AT P1 THRU P3

Occurrences of A in procedures P1 through P3.

A AT 100 THRU 2000

Occurrences of A in lines 100 through 2000.

A MOVE SET

Occurrences of A in MOVE and SET statements.

A I-O

Occurrences of A in I/O statements.

A AT #120 THRU #340

Occurrences of A in lines 120 through 340 inclusive.

See the section Finding COBOL Verbs later in this chapter for a list of verbs.

3.4.4 Special Queries

Some reserved names provide special query information. To perform a special query, prefix the data item-name with "_".


CALL

Provides a list of all the called subprograms. If the Exec-from toggle is on, the list also includes where they are executed from. It is possible to restrict the list to just calls of a certain type. The syntax is shown in Figure 3-2.



Figure 3-2: Syntax for Restricting the List of Subprograms

Examples:
CALL

All called subprograms.

CALL DATA

All calls to data items (note that these are less efficient than other calls and should be avoided if possible).

If no words follow CALL, the list includes subprograms of every type.


COPY

Displays the structure of the copyfiles forming the COBOL program. Nested copyfiles are indented. The source lines which begin and end each copyfile are highlighted.


DEADDATA

Provides a list of all potentially dead data items in the program. A data item is regarded as dead if neither it, nor any of its related data items (see below), are referenced in the Procedure Division. This generally gives a very good indication of whether an item declared in the Data Division is actually required by the program or not. Care should be taken with:


LABEL

Lists all the procedure-names in the program.


TIMES

Presents a list of program statistics. This consists of:

Lines of Source Total number of source lines
Lines of Code Lines of Procedure Division code
Comment Lines Number of comments (both * in column 7 and end of line comments "*>")
Text Comments Number of comments containing at least character A-Z, a-z, or 0-9. This generally provides a better indication of the number of meaningful comments in a program
Comment Ratio Number of text comments for every 100 source lines
Section Number of section-names
Statements Total number of COBOL statements
Paragraphs Number of paragraph-names
Files Number of files (FDs)
Data Items Number of data items
Conditions Number of conditions (level-88 items)
Screen-names Number of screen-names (Screen Section syntax)
Report Number of report-names (Report Writer syntax)
Constant Number of level-78 items
Call (by name) Number of call-by-name subprograms used
Call (by number) Number of call-by-number routines used
Call (data item) Number of data items used as called subprogram-names
Verb counts Number of verbs for each type of statement, including the number of statements for each type of group (for example, Program Exits, Arithmetic)
Maximum Nesting Maximum nesting level of in-line constructs; such as IF, EVALUATE, in-line PERFORM
Overlapping Performs Number of paragraphs/sections that lie in more than one PERFORM...THRU range
Program Volume An assessment of the number of operators and operands in the program. It is calculated as

(N1 + N2) LOG2 (n1 + n2)

where the parameters are:

N1 Total number of statements
N2 Number of references to all identifier-names
n1 Number of unique verb types
n2 Number of identifier-names
Total Data Data size of .int code
INT Code Procedure size of .int code (root segment only)
Linkage 01s Level-01 items in the Linkage Section

Note: The values of these statistics might not be strictly accurate for those programs compiled with an integrated preprocessor, and can vary slightly depending on the COBOL language dialect specified when you syntax-checked your program.



UNDECL

Provides a list of all the undeclared procedures, showing where they are referenced. This is generally empty, unless the result of syntax-checking your program is one or more syntax error 0348 messages ("Procedure name procedure-name undeclared, first used on line line-number").


UNEXEC

Provides a list of all procedure-names which are not actually referenced explicitly by the program. These procedure-names are not necessarily redundant since they might affect the end of PERFORM ranges, but this information can help to locate dead procedures.


UNREF

Provides a list of all data items which are not actually referenced explicitly by name in the Procedure Division.


WILDCARDS

If you include the wildcards "*" and "?" in the name you query, a list of all the names that match the wildcard string is produced, and their source line definitions are highlighted. You can specify "*" both at the beginning and end of the string.

The wildcard search can also be restricted to just procedure-names by adding "PROC", or to just data-names by adding "DATA" after the wildcard string.

Examples:
FLAG-* DATA Lists data-names beginning with "FLAG-".
*-EXIT PROC Lists procedure-names ending in "-EXIT".
*FILE* Lists all names containing the string "FILE".

3.4.5 Finding COBOL Verbs

At an Enter prompt, it is possible to find where you have used certain COBOL verbs in your program. The syntax is shown in Figure 3-3.



Figure 3-3: Syntax for Finding COBOL verbs

A list of recognized COBOL verbs is shown below.

ACCEPT
ADD
ALTER
CALL
CANCEL
CHAIN
CLOSE
COMMIT
COMPUTE
CONTINUE
DELETE
DISABLE
DISPLAY
DIVIDE
ELSE
ENABLE
END
END-EVALUATE
END-IF
END-INVOKE
END-PERFORM
END-SET
ENTER
ENTRY
EVALUATE
EXAMINE
EXEC
EXECUTE
EXHIBIT
EXIT
GENERATE
GO
GOBACK
IF
INITIALIZE
INITIATE
INSPECT
INVOKE
MERGE
MOVE
MULTIPLY
NEXT
NOTE
ON
OPEN
OTHERWISE
PERFORM
READ
READY
RECEIVE
RECOVER
RELEASE
RESET
RETURN
REWRITE
ROLLBACK
SEARCH
SEND
SERVICE
SET
SORT
START
STOP
STRING
SUBTRACT
SUPPRESS
TERMINATE
TRANSFORM
UNLOCK
UNSTRING
WHEN
WRITE

In addition, the following words refer to COBOL syntax as follows:

Word
Syntax
DEPENDING GO TO ... DEPENDING ON ..
EXCEPTION Exception conditions such as ON SIZE ERROR and AT END
EXIT-PROGRAM EXIT PROGRAM (not EXIT)
INLINE In-line PERFORM statements
PREPROCESSED Statements that have been replaced by an integrated preprocessor, such as CICS
STOP-RUN STOP RUN (not STOP "message")
THRU PERFORM ... THRU
WHEN-OTHER WHEN OTHER (not WHEN)
EXIT-PERFORM EXIT PERFORM
EXIT-CYCLE EXIT PERFORM CYCLE
EXIT-PARA EXIT PARAGRAPH
EXIT-SECTION EXIT SECTION

The following words identify groups of verbs:

Word
Group of Verbs
ARITH Arithmetic statements: COMPUTE, ADD, MULTIPLY, DIVIDE, and SUBTRACT.
END-SCOPE ANSI'85 END-verbs. For example, END-IF and END-READ.
I-O File operations: OPEN, CLOSE, READ, WRITE, DELETE, START, and REWRITE.
PGMEXIT Program exits: STOP RUN, EXIT PROGRAM, and GOBACK.
Examples:
COMPUTE
All COMPUTE statements.
I-O AT READ-FILES
I/O statements in the procedure READ-FILES.
ARITH 
All arithmetic statements.
PGMEXIT
All program exits (EXIT PROGRAM, STOP RUN, GOBACK).
ADD AT #120 THRU #340
All ADD statements in lines 120-340.

3.4.6 Qualified Names

CSI supports qualified data-names. When you query an item, you can specify A OF B as opposed to A OF C. If CSI is unable to uniquely resolve the data-name you gave it, it provides a list of synonyms of the item.

Example:

If you have the following data declaration:

  01  B.
     03  A   PIC X.
  01  C.
     03  A   PIC X.

querying the name "A", CSI gives you a list showing A OF B, and A OF C.

3.5 Functions, Menus, and Toggles

Many of the CSI functions that you would commonly use are available on the main menu (see Figure 3-4). Some of these functions have subfunctions with additional menus. The functions either perform an action, change the value of a toggle, or display a menu of further functions.



Figure 3-4: Main Menu

The functions available from the main menu and its submenus are listed below in alphabetical order. For those functions that appear on submenus, the submenu is identified.


Analyzer

Toggles the display of Analyzer totals in columns 72 through 80 on and off. It can be changed only when the current program has been syntax-checked with the ANALYZE Compiler directive.

Available from the Display submenu.


Both-source-and-report

Prints the highlighted source and report information.

Available from the Print-to-file submenu.


Calls

Toggles the inclusion of CALL statement information in "executed-from" and "executes" information on and off.

Available from the Options submenu.


Child

Queries the first child of the current data item.

Available from the Query submenu.


Clear-all-tags

Clears all the tags.

Available from the Tag submenu.


Clear-return-stack

Each time you perform a Locate function, the position of the located item is added to a stack, so that if you perform several Locate functions without intervening Return functions, you can then perform several Return functions to step back through your located positions. The Clear-return-stack function clears this stack.

Available from the Locate submenu.


Comment-color

Comment lines (those with an asterisk in column 7) can optionally be displayed in a different color, which can be configured (see the description of the Comment-color toggle in the section Configuration Options later in this chapter). This key toggles between three different states:

Available from the Display submenu.


Compress

Toggles the source listing between a compressed listing (showing only the highlighted source lines) and a normal listing (all source lines are displayed). See also the Expand function.


Csr (Cursor)

Queries the item at the cursor position. In the report window, the item queried is the one on the current line.


Cursor (Locate)

The effect of this key depends on whether the source or report window is active.

When the source is active, the source line containing the definition of the item at the cursor position is located. The position you were at is stored, and you can quickly return there by pressing R (Return) from the main menu. Successive Locate functions stack the positions they were performed from, so Locate and Return functions can be used to navigate around the program.

When the report window is active, the source is positioned at the line relevant to the selected line in the report window.

Available from the Locate submenu.


Cursor (Query)

Queries the item at the current cursor position. It is the same as using F6=csr on the main menu.

Available from the Query submenu.


Current-file

Displays the name of the source file which contains the current source line. This can be useful if you have programs with many copyfiles.

Available from the Display submenu.


Data-in-procedure

When this toggle is highlighted, procedure-name queries include information concerning the data-name used by the procedure. See the section Procedures (Paragraphs and Sections) earlier in this chapter for information on where this is used.

Note that when the Data X Procedure (DXP) toggle is highlighted, data-name queries include the procedures in which they are found.

Available from the Options submenu.


Data-selector

Determines what type of data item occurrences are highlighted. The state of this toggle is displayed on the divider line. The toggle can be set to:

All All occurrences are shown
Uses Only uses and modifications are shown
Mod Only modifications are shown
Defn Only definitions are shown.

This toggle also determines which data items are included in the related data item list (see below). When set to "Mod" or "Uses", only data items which are respectively modified or used by the Procedure Division are included in the list of related data items.

Available from the Options submenu.


Display

Enables you to alter various display options.

Whenever this menu is active, the cursor keys move the report window around the screen. The Home, PgUp, End, and PgDn keys move the window automatically at the corners of the screen. In these latter positions, the window is automatically repositioned whenever a new query is performed.

This submenu provides functions for altering the screen display and clearing tags. See Figure 3-5.



Figure 3-5: Display Menu

For a description of the functions on this menu, see Analyzer, Comment-color, Current-file, Escape, Perform-thrus, Print-to-file, Seq-no's and Tags.


Enter (Locate)

This enables you to locate the definition of a name you key in. You can enter one of the following:

Available from the Locate submenu.


Enter (Query)

Enables you to enter a name to query. It is the same as using F5=enter on the main menu.

Available from the Query submenu.


Escape

Returns to the main menu from submenus, and exits the main menu.


Exec-from

Toggles the "executed-from" information on and off. When on, the information provided for procedures and subprograms queried include where they are executed from. When you change this toggle, the report and source windows are automatically updated where necessary.


Executes

Toggles the "executes" information on and off. When on, the information provided for procedures queried include what other procedures and called subprograms they execute. When you change this toggle, the report and source windows are automatically updated where necessary.


Expand

Toggles the source listing between a compressed listing (showing only the highlighted source lines) and a normal listing (all source lines are displayed). See also the Compress function.


Go-to-tag

Returns to a previously tagged line. Pressing "G" repeatedly cycles between all the tagged lines in the order in which they were set.

Available from the Tag submenu.


Go-tos

Toggles the inclusion of GO TO statement information in "executed-from" and "executes" information on and off.

Available from the Options submenu.


Hide

Toggles between hiding and showing the report window. If you hide the report window when it is active, the focus automatically shifts to the source.


Locate

Takes you to the Locate submenu, enabling you to locate various lines. The locate submenu provides ways of quickly locating source lines in the program. See Figure 3-6.



Figure 3-6: Locate Menu

For a description of the functions on this menu, see Clear-return-stack, Cursor (Locate), Enter (Locate), File-control, File-section, Linkage, Next-procedure, Previous-procedure, Screen-section, Start-procedure and Working-storage.


File-control

Positions you at the definition of the first file item (usually a SELECT statement in the File-Control of the Environment Division).

Available from the Locate submenu.


File-section

Positions you at the definition of the first File-Section item (usually the first record of an FD).

Available from the Locate submenu.


Linkage

Positions you at the definition of the first Linkage Section item.

Available from the Locate submenu.


Next-procedure

Positions you at the next paragraph or section definition in the source (only available when source is active).

Available from the Locate submenu.


Options

Takes you to the Options submenu, which enables you to alter those toggles which affect the information returned by a query.

The exact information returned for each query depends upon the setting of many of the toggles on this menu. None of the changes you make take effect until you perform another query, either by querying the current item again or querying a new item. See Figure 3-7.



Figure 3-7: Options Menu

For a description of the functions on this menu, see Calls, Data-selector, Go-tos, Data-in-procedure, Paragraphs, Perform-level, Performs, Related-data, Requery, and Sort.


Paragraphs

Toggles the inclusion of paragraphs in procedural queries on and off. When on, paragraphs are shown in "executes" information. When off, paragraph-names are not shown and "executed from" information shows the parent sections instead of any paragraph-names.

Available from the Options submenu.


Parent

Queries the parent of the current item.

Available from the Query submenu.


Perform-level

The two function keys assigned to this function, F7 and F8, respectively decrease and increase the PERFORM-level setting. See the section Procedures (Paragraphs and Sections) earlier in this chapter, for information on where this is used.

Available from the Options submenu.


Perform-thrus

When this toggle is on, definitions of procedure-names which are interior to PERFORM ... THRU ranges are marked in columns 1 through 6. For well-behaved programs, this gives a good indication as to whether execution can fall through a paragraph-name or not.

Available from the Display submenu.


Performs

Toggles the inclusion of PERFORM statement information in "executed-from" and "executes" information on and off.

Available from the Options submenu.


Posn-exit

Returns to the Editor or Animator, positioning you at the cursor line and column. In the report window, this is the same as if you had performed a Locate-Cursor, but returned to the Editor/Animator instead of the source window. If necessary, the Editor loads the appropriate copyfile. Only the Animator display is relocated, not the execution line of the program.

CSI does not compensate for the replaced lines in COPY...REPLACING files.


Prev/Next

Positions the source to display the previous/next highlighted source line. When the report window is active, the source scrolls to display the current line, and the report window remains unaltered. These functions are not available when the source listing is compressed.


Previous-procedure

Positions you at the previous paragraph or section definition in the source (only available when source is active).

If the program does not contain the relevant line, the position remains unaltered and a message is displayed.

Available from the Locate submenu.


Previous-queries

A list of items previously queried is displayed. Select the one you want to requery and press Enter. Press Escape to return without querying a previous item.

Available from the Query submenu.


Print-to-file

This function displays the print-to-file submenu as shown in Figure 3-8.



Figure 3-8: Print Menu

The Print-to-file submenu enables you to append the current query report and/or highlighted lines to an ASCII line sequential file. The name of this file can be configured. The default filename is csi.dat, and the file is written to the current directory.

Available from the Display submenu.

For a description of the functions on this menu, see Source-only, Report-only, and Both-source-and-report.


Query

Takes you to the Query submenu, enabling you to query other items. See Figure 3-9.



Figure 3-9: Query Menu

For a description of the functions on this menu, see Child, Cursor (Query), Enter (Query), Parent, Previous-queries, and Same-level.


Related-data

The state of this toggle is shown on the status line. It has three settings:

Off
Child Data item queries include details of the child items of the target item.
Related Data item queries include details of the related data items of target item.

Data item A is regarded as a related definition of data item B, if any of the following conditions are true:

Available from the Options submenu.


Report-only

Prints only the information in the current query report.

Available from the Print-to-file submenu.


Requery

Pressing Enter requeries the current item, with the new toggle settings, and returns to the main menu.

Available from the Options submenu.


Return

Returns to a position from which a Locate function was previously performed.


Same-level

Queries the next data item at the same level as the current item.


Screen-section

Positions you at the definition of the first Screen Section name.

Available from the Locate submenu.


Seq-no's

Toggles the display of sequence numbers in columns 1 through 6 on and off.

Available from the Display submenu.


Set-tag

Sets a tag at the current source line. Up to 16 source lines can be tagged. This function is not available in the report window. Lines which have been tagged are usually indicated in columns 1 through 6 of the source by a "Tag" indicator. These can be optionally hidden by pressing "T" on the display menu.

Available from the Tag submenu.


Sort

Set this toggle to sort items into alphabetic order rather than source code order.

When an item has an OCCURS clause, only the first occurrence is considered as being possibly dependent upon or a dependent of other data items.

SAME RECORD AREA is not supported.

Available from the Options submenu.


Source-only

Prints the highlighted lines of your source.

Available from the Print-to-file submenu.


Start-procedure

Positions you at the start of the PROCEDURE DIVISION label.

Available from the Locate submenu.


Tag

Takes you to the Tag submenu, enabling you to set and clear tags.

CSI enables you to set and maintain program-wide tags.

For a description of the functions on this menu, see Clear-all-tags, Go-to-tag, Set-tag , and Un-set-tag.


Tags

Toggles the display of tags on and off.

Available from the Display submenu.


Un-set-tag

Clears the tag at the current line.

Available from the Tag submenu.


Window

Switches the focus between the source and report window. If the report window has been hidden, it is automatically redisplayed.


Working-storage

Positions you at the definition of the first Working-Storage Section item.

Available from the Locate submenu.


3.6 Configuration Options

Many of the default toggle settings and colors used by CSI are configurable, and can be specified in the local configuration file under the configuration tag [MF-CSI]. See the chapter Configuring Development Tools in your Getting Started for information on using configuration files.

Each configuration option must start on a new line and occupy a single line. Case is not significant. Space and colon (:) are regarded as separators and are ignored.

For example, if you wish to set the Exec-from toggle to be initially OFF and the value of the Data-selector option to be "Uses", enter the following three lines in the local configuration file:

Example:
[MF-CSI]
executed-from off
data-filter 1

Additional changes would be entered as single lines following the [MF-CSI] tag but preceding any other tag-names. In order to check that your configuration options are syntactically correct, run the Mfcsi utility. It parses the configuration options and marks any erroneous lines.

There are three groups of items that can be configured:

3.6.1 Toggle Settings

The initial settings of many of the toggles available on the user interface can be configured.


CALLS {ON OFF}

Specifies the initial setting of the calls toggle (see the Options menu).

Default:

CALLS ON


COMMENT-COLOR integer

Determines the initial setting of the 3-way comment color toggle.

0 = All text shown normally (default)
1 = Comment lines shown in dark color
2 = Non-comment lines shown in dark color.

Default:

COMMENT-COLOR 0


DATA-FILTER integer

Determines the initial setting of the Data-selector option:

0 = All (default)
1 = Uses
2 = Modification
3 = Definition

Default:

DATA-FILTER 0


EXECUTED-FROM {ON OFF}

Determines the initial setting of the Exec-from toggle.

Default:

EXECUTED-FROM ON


EXECUTES {ON OFF}

Determines the initial setting of the Executes toggle.

Default:

EXECUTES ON


GO-TOS {ON OFF}

Specifies the initial setting of the Go-tos toggle (see the Options menu).

Default:

GO-TOS ON


PARAGRAPHS {ON OFF}

Specifies the initial setting of the Paragraphs toggle (see the Options menu).

Default:

PARAGRAPHS ON


PERFORMS {ON OFF}

Specifies the initial setting of the Performs toggle (see the Options menu).

Default:

PERFORMS ON


PERFORM-LEVEL integer

Specifies the initial setting of the Perform-level option.

Default:

PERFORM-LEVEL 1


PROCEDURE-DATA {ON OFF}

Specifies the initial setting of the Data-in-procedure option.

Default:

PROCEDURE-DATA OFF


RELATED-DEFNS {ON OFF CHILD}

Determines the initial setting of the Related-definitions toggle.

Default:

Default: RELATED-DEFNS OFF


SHOW-ANALYZER {ON OFF}

Determines the initial setting of the Analyzer Display option.

Default:

SHOW-ANALYZER OFF


SHOW-THRU {ON OFF}

Determines the initial setting of the Perform-thru option.

Default:

SHOW-THRU OFF


3.6.2 Color Configuration

CSI defaults to using the same display attributes as the rest of Server Express. However, many of the attributes can be configured independently. For example, you can alter the color of the source listing to create a visible difference between CSI and Animator.

The color configuration options are prefixed by "COLOR-" and the monochrome options are prefixed by "MONO-".

The options available are described below.


BORDER

Border of report window.

Defaults to system attribute : 4


DARK

Comment lines when comment-color is changed.

Defaults to system attribute : 1


SOURCE-HI

Highlighted source lines.

Defaults to system attribute : 5


SOURCE-CURSOR

Current line in source window.

Defaults to system attribute : 4


SOURCE-CURSOR-HI

Current source line, when highlighted.

Defaults to system attribute : 6


REPORT

Text in report window.

Defaults to system attribute : 7


SOURCE

Source text.

Defaults to system attribute : 7


REPORT-CURSOR

Current line in report window.

Defaults to system attribute : 2

3.6.2.1 Color Configuration Examples

Examples of color configuration are given below.

Example 1:

To alter the source text attribute for color systems to green on black, you should include the line:

COLOR-SOURCE GREEN ON BLACK

Monochrome attributes are specified as either "REVERSE-VIDEO", "UNDERLINE" or "NORMAL", together with "HIGHLIGHT" and/or "BLINK".

Example 2:

To alter the current report line attribute for monochrome displays to highlighted underline, you should include the line:

MONO-SELECT-BAR HIGHLIGHT UNDERLINE

3.6.3 Miscellaneous Configuration Options

Some other options that you can configure for CSI are listed below:


COBIDY-FIRST on/off

Default: COBIDY-FIRST OFF

When ON, and CSI is accessed from the Editor, .idy files are located only along the path specified by the COBIDY environment variable. This option is intended for use in environments where the .idy files are in different directories from the source files, and when any .idy files in the source directories are to be ignored.


DUMP-FILE filename

Default: DUMP-FILE csi.dat.

Specifies the name of the line sequential file to which reports can be dumped.


LAST-QUERIES integer

Default: LAST-QUERIES 15

Specifies the number of last-queries which are held. integer must be between 1 and 15 inclusive.


NEW-LOCATE on/off

Default: NEW-LOCATE OFF

When ON, each new query causes CSI to automatically relocate to the most appropriate line.


REPORT-ALIGN integer

Default: REPORT-ALIGN 1

Determines the initial position of the report window.

0 = Top-left
1 = Top-right (default)
2 = Bottom-left
3 = Bottom-right

REPORT-HIDE on/off

Default: REPORT-HIDE OFF

Determines if the report window is initially hidden or not.


SEQ-NUMBERS on/off

Default: SEQ-NUMBERS ON

Determines whether sequence numbers are displayed in columns 1 through 6 or not.



Copyright © 2000 MERANT International Limited. All rights reserved.
This document and the proprietary marks and names used herein are protected by international law.

PreviousDevelopment Environment Menu System Data File EditorNext