• Keine Ergebnisse gefunden

$TEXT Facility

Im Dokument PROGRAMMER GUIDE (Seite 77-81)

The CP-6 user documentation -- incLuding this Guide -- is created via the STEXT.:DOCUM facility. This facility can produce several forms of

documentation from source text fiLes: hard-copy documents, document unit-record fiLes for eLectronic distribution, and HELP fiLes.

STEXT capabilities incLude:

• Assembly of complete manuals from muLtipLe fiLes.

• Automatic generation of titLe page, tabLe of contents, and index.

• Automatic layout of headings, tables, and figures.

• Generation of HELP files from source text fiLes.

FoLlowing the conventions discussed in this section assures device-independent output for hard-copy and HELP fiLes.

Files that can be processed by $TEXT are keyed fiLes buiLt via EDIT. The files contain text, plus TEXT controL words and macro control words. Once source text files are buiLt, compiling a complete document is a fast, simple process. "Document assembly" can be requested through a menu-driven interface described in this section. The same interface allows creation of a HELP file;

see "Preparing On-line (HELP) Documentation" in this section for details.

The tools for the user of STEXT include:

• The EDIT processor to build source text files.

• The menu-driven interface, STEXT.:DOCUM (which uses SFASTEXT.:DOCUM and invokes the TEXT processor).

• Macros which are stored in :LIBRARY (e.g., :MAT.:LIBRARY).

Conventions for text source files are highlighted in this section. A full description of STEXT capabilities is provided in guide CE59. Full information on TEXT is provided in the CP-6 Text Processing Reference Manual (CE48); a HELP file is also available. In addition, the CP-6 Text Processing

Administrator Guide (CE52) contains related information.

CE62-00 $TEXT Facility 7-1

File Naming Conventions following standard introductory material:

the Preface, Title Page, a call to the Table of Contents file, About This Manual, and the Syntax Notation page.

The numbered document sections.

The appendixes.

The glossary.

Table of Contents and Index files are created and included in a hard-copy manual during document assembly.

NOTE: After processing by STEXT, the resulting document may be printed in hard copy form or stored in one unit record file (from which multiple copies could be made). The name for such a unit record file may be any legal FID.

Document Assembly

The user can initiate a dialog with STEXT during which it prompts the user for all the information required to perform document assembly.

To begin the document assembly dialog with STEXT, the user enters the

Extra Files>

Go for It?>

Whether to generate a table of contents, an index, and/or a typeset header file as part of the document assembly.

Whether to begin the assembly process, initiate a response change mode, or terminate document assembly.

All user responses are followed by a <CR>. For all prompts, there is a

default. The user selects the default by entering <CR> only. Typing HELP<CR>

in response to any prompt (except "Go for it") displays appropriate responses to the prompt. For complete information on document assembly, please see CE59.

Summary of Control Words and Macros

Text source files contain text, TEXT control words, and macro control words.

TEXT control words regulate indentation, spacing, etc. The macros control placement and underlining of section and subsection headings, positioning of headings and table columns, positioning of figure and table headings, and identification of index entries.

Each control word or macro is placed on a line by itself, beginning in the first character position of the line. ControL words begin with a period in position 1. Macros begin with periods in positions 1-2. Table 7-1 summarizes the subset of TEXT control words frequently used in fiLes processed by STEXT.

Table 7-2 summarizes the frequently used macros recognized by STEXT.

Table 7-1. TEXT Control Word Summary Control Word Description

.SPB en]

.SPF en]

• F I F

.FIN

• INL n

CE62-QQ

Creates n blank line(s), where a page break is acceptable

Creates n blank line(s), where a page break is unacceptable

Causes the following copy to appear on output exactly as it is entered in the file

Causes text formatting to resume. That is, after a .FIF and portion of text to be output exactly as entered in the file, .FIN causes text to fill full lines in the output produced •

Indents the following text lines by n positions

Summary of Control Words and Macros 7-3

TabLe 7-1. TEXT ControL Word Summary (cont.) ControL Word Description

.UNL n

.BRP

Starts the foLLowing Line n positions to the Left from the indent position specified by the previous .inL controL word

In fiLes to be processed by STEXT, "break page" (.BRP) is restricted to use in the end-of-fiLe sequence. (STEXT performs page Layout.>

.SRV name expr

• TRF xy

Macro

In fiLes to be processed by STEXT, .SRV SECTION {nl"x"}

creates the section or appendix identifier for use on page 1, in page numbering, and in the tabLe of contents. The

identifier is a number for sections, a Letter for appendixes (e.g., "A"), or "g" for a gLossary •

TransLates character x to character y untiL the next .trf controL word is encountered. STEXT assumes that the character

A is to be transLated to a bLank (i.e., it assumes .TRF A ) except in figures.

Table 7-2. Macro Summary Description

•• :LOH "head"

Creates a section name •

•• :L{1121314}H "head[;help_info)"

CE62-00

Creates a subsection head of level 1-4, formatted according to STEXT conventions. For levels 1-3, creates an entry in the table of contents and index, if requested. By default, creates a HELP topic of level 1-3 heads with associated level 4 heads as

subtopics.

Summary of Control Words and Macros 7-4

Table 7-2. Macro Summary (cont.) Macro Description

•• :MAT "table info"

•• :END

Creates a table from subsequent text, controlling spacing before and after the table, table title, table headings, and tabte layout.

Table types are as follows: matrix, 2-column formatted, and unformatted. Also creates an entry in the list of tables, if a table of contents ;s requested •

Terminates table text •

•• :FIG "fig_info"

Creates a figure from subsequent text, controlling spacing before and after the figure, placement of figure title, and layout. Also creates an entry in the List of figures, if the tabLe of contents is requested •

•• :IDX "index info"

Creates an index entry for a term incLuded or impLied in the preceding text •

•• :HLP "[manuaL textJ[;help_textJII

Creates alternate wording for the manuaL and for the HELP file.

Im Dokument PROGRAMMER GUIDE (Seite 77-81)