Release 10.1A: OpenEdge Deployment:
Managing 4GL Applications

> ## PROTERMCAP syntax

> This section explains the following:

> - The general syntax rules that apply when specifying fields in any of the six `PROTERMCAP` sections.

> - The syntax rules that apply when specifying string values within a field. String values can occur in the terminal capabilities section, the key bindings section, and the color table section.

> Syntax rules that apply only to specific sections of the `PROTERMCAP` file are explained in context.

> ##### General syntax

> A `PROTERMCAP` entry is a single logical line that contains many fields. The syntax for an entry is as follows:

> - Each field is terminated by a colon (:). (Use the octal equivalent \072 to specify a colon that is not a terminator.)

> - Unless stated otherwise, a field cannot contain embedded separators. Spaces and tabs improve readability, but they are considered empty fields and must be terminated by a colon.

> - Comment lines begin with a pound sign (#), and can only occur at the beginning and end of each `PROTERMCAP` terminal entry (that is, before the terminal name line and after the pointer to key functions line).

> - To enhance readability, the `PROTERMCAP` file, as installed, contains as many physical lines as there are fields. Each physical line in the entry contains the following, in the order listed:

> - An empty field consisting of a tab character.
> - A field definition.
> - A backslash (\).
> - A return.

> The backslash indicates that the terminal entry continues on the next physical line of the file. If you need to include a literal backslash in a field, use two backslashes.

> The following code fragment from the entry for the Wyse 370 shows the use of the colon, tab, space, backslash, and return characters:

>     wy370|wyse370|wyse_370|wyse 370 running in native mode:\
>       :  :\
>       :ct:\
>       :cm=\E[%i%d;%dH:\
>       :co#80:\
>       :li#24:\
>       :G1=k:
>       :  :\
>       :GO(F1)=\EOP:\
>       :HELP(F2)=\EOQ:\
>       :  :\
>       :COLOR 5 RED/BLACK=\E[31;40m:\E[m:\
>       :COLOR 6 GREEN/BLACK=\E[32;40m:\E[m:

> ##### String syntax

> Certain fields in the capabilities, key bindings, and color sections are specified using strings. Strings are typically a combination of command sequences, literal values, and encoded arguments that tell OpenEdge how to control some aspect of the display.

> Table 4–7 show the symbols that are common to all strings. Symbols that are unique to strings specified in the capabilities, key bindings, or color sections are explained in context.

> Table 4–7: Syntax for specifying string values
> Mnemonic | Description
> --- | ---
> \E | ESC (ASCII 27)
> \n | New line
> \r | Return
> \t | Tab
> \b | Backspace
> \f | Form feed
> \`999` | Octal representation of a character. A colon (:) within a string must be represented as \072 and a null character as \200.
> ^`x` | CTRL+x, where `x` represents an appropriate character. For example, ^N represents CTRL+N.
> \^ | ^
> \\ | \

> Some terminal types require you to specify a delay period, also called a padding constant, with certain string capabilities. The delay, in milliseconds, gives the terminal adequate time to execute the command. Specify this delay as an integer value after the equals sign (=) in a string, as shown in the following example:

>     :cm=20\E[%i%d;%dH:\

> This tells OpenEdge to wait 20 milliseconds after sending the cursor motion (cm) command sequence.

> You can optionally follow an integer delay value with an asterisk (*) for commands that affect more than one line of the display. In this case, OpenEdge delays the specified time for each line affected by the command. However, this significantly degrades performance and usually is not required.

> When you specify proportional delay, you must specify an integer as the delay in a string field. It cannot have a fractional part; for example, a delay of 1.5* is not valid.

> Note: Do not specify a padding constant with the GS, GH, GV, GE, G1, G2, G3, and G4 capabilities.

Copyright © 2005 Progress Software Corporation www.progress.com Voice: (781) 280-4000 Fax: (781) 280-4095