next up previous 62
Next: Viewing a source file
Up: Browsing using HTML
Previous: Browsing using HTML

Locating a source file

The top level page of the source code browser is a form which can be filled in to request a particular source file. It consists of the following parts:

Name of item
The name of the file or function/subroutine to locate, or a regular expression matching a file or routine (more detail in section 4.1.1).
Type of item
Describes how to interpret the ``Name of item'' box. Select one of:
The item is a Fortran or C function or subroutine. This is case sensitive. For C use the name of the function exactly as it occurs in the source code. For Fortran, use the routine's name in lower case with an underscore appended; however, if the case is wrong or the underscore is omitted the browser will still probably find the right routine.
The item is a filename. This is case sensitive.
The browser will try both of the above options (File and Routine).
Regular expression
The item name is a Perl 5 regular expression, interpreted case-insensitively, to match the name of a file or function/subroutine (note it does not match the full text of source files). For most practical purposes, Perl regular expressions are a superset of ordinary regular expressions, so they can be treated like the argument of a `grep -i' command.
(More detail in section 4.1.3).
Name of package (optional)
If one of the listed packages is selected, it serves as a hint about where the file or routine being searched for might be. It is used as follows: if a file or routine of the given name is found in the package specified, then that one will be presented. If it is not in that package, or if no package is specified, then any such item in the whole source tree will be presented. In particular, this means that even when one package is specified here, a routine from another package may be presented.
If the Type of item is ``Regular expression'' however, then filling in this field will restrict the search to the named package. (More detail in section 4.1.2).
If the type of item is ``Routine'' or ``File'', then submitting the form will take you to the unit requested, or a message that no such unit can be found (note that these will take you to the top of the file, not necessarily where the requested routine begins -- if this makes it hard to find the right place, you can browse the package and follow a link to the routine, as described below). If the type of item is ``Regular expression'', it will present a list of links to matching files.

Instead of entering the name of the file or routine you wish to see, you can browse the contents of a given package. Below the form is a list of links to all the available packages. Following one of these links (or equivalently selecting the package name in the `Name of package' box without filling in the `Name of item' field) will take you to a page giving more information about the package requested. This will contain the same form at the top, but below it are links to files from the package grouped by category:

Links to every file in the package.
Links to every C and Fortran function and subroutine definition identified in the source files.
Starlink documents
Links to any SUNs and SSNs which form part of the package (although not necessarily all those relevant to the package).
Links to `tasks' in the package. This is rather loosely defined, but it is intended to be the names of commands which can be invoked from the Unix shell or ICL. Because the way these are identified is rather ad hoc, the list may be incomplete and/or contain spurious entries.
Sometimes the ``Files'' or ``Routines'' heading is a hyperlink to the actual lists of links, rather than having the list on the page.

Following any of the listed links will take you to one of the files in the package.

next up previous 62
Next: Viewing a source file
Up: Browsing using HTML
Previous: Browsing using HTML

SCB --- Source Code Browser
Starlink User Note 225
M. B. Taylor
10 December 1999