HILITE—Enhanced Edit Coloring
HILITE is used to control the use of color in the editor by changing the settings for the enhanced color and language-sensitive editing features.
HILITE with no operands presents a dialog (see The HILITE dialog) that allows you to change coloring options, and to see which keywords are supported for each language.
Language and logic hiliting is not supported for ASCII or UTF-8 editing sessions and the HILITE command is not available during these edit sessions.
Syntax
- ON
- Sets program coloring ON and turns LOGIC coloring off.
- OFF
- Sets coloring OFF, with the exception of cursor, find, and parenthesis highlighting.
- LOGIC
- LOGIC highlighting matches logical language-specific keywords
in the same color. If an unmatched closing keyword is found,
such as END for PL/I or :eul. for BookMaster®,
it is highlighted in reverse video pink only if HILITE LOGIC
is active. When logic is being highlighted, only comments are highlighted
along with it.
Logic highlighting is available only for PL/I, PL/X, REXX, OTHER, C, SKELS, Pascal, and BookMaster. HILITE LOGIC turns on both IFLOGIC and DOLOGIC.
Note: LOGIC highlighting can be turned off by issuing HILITE ON, HILITE NOLOGIC, or HILITE RESET commands. Changing the HILITE language does not change the LOGIC setting. - IFLOGIC
- Turns on IF/ELSE logic matching. IFLOGIC matches IF and ELSE statements. When IFLOGIC is enabled, unmatched ELSE keywords are highlighted in reverse video pink.
- DOLOGIC
- Turns on DO/END logic matching. DOLOGIC matches logical blocks such as DO/END in PL/I or :ol/:eol in BookMaster. For the C language, DOLOGIC matches curly braces ({ and }). C trigraphs for curly braces are not recognized and are not supported by DOLOGIC highlighting. When DOLOGIC is enabled, unmatched logical block terminators (such as END keywords in PL/I, :e tags in BookMaster or right braces ( } ) in C) are highlighted in reverse video pink.
- NOLOGIC
- Same as ON.
- AUTO
- Allows ISPF to determine the language. See Automatic language selection for more information.
- DEFAULT
- Highlights the data in a single color.
- OTHER
- Highlight the data as a pseudo-PL/I language. Limited CLIST support is also provided by OTHER.
- ASM
- Highlights the data as Assembler.
- BOOK
- Highlights the data as BookMaster.
- C
- Highlights the data as C.
- COBOL
- Highlights the data as COBOL
- DTL
- Highlights the data as Dialog Tag Language.
- HTML
- Highlights the data as HTML.
- IDL
- Highlights the data as IDL.
- JCL
- Highlights the data as MVS™ Job Control Language.
- PANEL
- Highlights the data as ISPF Panel Language.
- PASCAL
- Highlights the data as Pascal.
- PLI
- Highlights the data as PL/I.
- REXX
- Highlights the data as REXX.
- SKEL
- Highlights the data as ISPF Skeleton Language.
- SUPERC
- Highlights the data as a SuperC Listing.
- XML
- Highlights the data as XML.
- MARGINS [left-margin | * [right-margin | * ] ]
- Specifies either or both of the left-margin or right-margin parameters
for languages C, PL/I, and PL/X. The MARGINS keyword can be included
on the same command that includes one of these languages. It cannot
be specified when the language AUTO is specified, even if the language
would subsequently be determined to be C, PL/I, or PL/X.
- left-margin
- The left hand margin for processing the language source. The value must be within the range as defined by the language. The maximum value is 254 for C, 100 for PL/I, and 65 for PL/X. If left-margin exceeds the last input column or if an asterisk (*) is specified, the default left margin is obtained from the ISPF configuration table keyword for this language (HILITE_MARGIN_C, HILITE_MARGIN_PLI, or HILITE_MARGIN_PLX).
- right-margin
- The right hand margin for processing the language source. The value must be within the range as defined by the language. The maximum value is 255 for C, 200 for PL/I, and 80 for PL/X. If right-margin exceeds the last input column or if an asterisk (*) is specified, the default right margin is obtained from the ISPF configuration table keyword for this language (HILITE_MARGIN_C, HILITE_MARGIN_PLI, or HILITE_MARGIN_PLX).
- RESET
- Resets defaults (LANG AUTO, COLOR ON, LOGIC OFF, FIND ON and CURSOR ON).
- PAREN
- Toggles parenthesis matching. When parenthesis matching is active, only comments are specially colored. All other code appears in the default color. Note that extra parenthesis highlighting is always active when highlighting is active.
- FIND
- The HILITE FIND command toggles the highlighting color of any
string that would be found by an RFIND. The user can select the highlight
color. The default is reverse video white.
Only non-picture strings are supported, and the only additional qualifiers recognized are hex strings (X'…'), character strings (C'…'), text strings (T'…'), WORD, PREFIX and SUFFIX, and boundaries specified in the FIND command. Hex strings may be highlighted, but non-displayable characters are not highlighted. Labels are ignored when FIND strings are highlighted.
Because FIND highlighting is not quite as robust as the FIND command itself, the editor may highlight more occurrences of the FIND string than FIND would actually locate. The FIND operand toggles the display of search strings. If HILITE FIND is issued when FIND highlighting is in effect, FIND highlighting is disabled. Similarly, if FIND highlighting is disabled, the HILITE FIND command enables it.
Note: RESET has been enhanced, through the addition of a FIND operand, to temporarily disable the highlighting of FIND strings until the next FIND, RFIND, CHANGE, or RCHANGE command is issued. RESET with the FIND operand (or no operands at all), temporarily disables the highlighting of FIND strings. - CURSOR
- The CURSOR operand toggles the highlighting of the phrase that
contains the cursor in a user selectable color. The default is white.
Cursor highlighting in Edit is performed in a manner similar to the way it is done in Browse. The entire phrase from the previous blank to the next blank is highlighted. The CURSOR operand toggles cursor highlighting. If HILITE CURSOR is issued when CURSOR highlighting is in effect, CURSOR highlighting is disabled. Similarly, if CURSOR highlighting is disabled, the HILITE CURSOR command enables it.
- SEARCH
- HILITE SEARCH finds the first unmatched END, ELSE, }, or ) above
the last displayed line on the screen. If a mismatched item is found,
the file is scrolled so that the mismatch is at the top of the screen.
The search for mismatches only occurs for lines above the last displayed
line, so you may need to scroll to the bottom of the file before issuing
the HI SEARCH command.
Search is not available when the DEFAULT language operand is used. Search for language keywords is only supported for languages which supported by the logic option.
- DISABLED
- Turns off all HILITE features and removes all action bars. This benefits performance at the expense of function. Since DISABLED status is not stored in the edit profile, you need to reenter this operand each time you enter the editor. When DISABLED is in effect, keylists are unavailable for that edit session.
Description
The HILITE primary command can be used to highlight, in user-specified colors, many language-specific constructs, program logic features, the phrase containing the cursor, and any strings that match the previous FIND operation or those that would be found by an RFIND or RCHANGE request. In addition, when HILITE is entered with no operands, a dialog appears that allows you to set default colors for the data area in non-program files, for any characters typed since the previous Enter or PF key entry, and for strings located by FIND.
Both HI and HILIGHT are valid synonyms for HILITE.
When the code page being used is not the English codepage, the HILITE primary command does not detect key sequences if the control character within the key sequence has a different binary representation in the code page being used from the binary representation in the codepage used for English. For example, in the C language, a '\' is used as an escape sequence character to influence the interpretation of the next character; however, the '\' has a different binary representation in different codepages.
- Highlighting is not available for edit sessions that involve:
- Data sets with record lengths greater than 255
- Mixed mode edit sessions (normally used when editing DBCS data)
- Formatted data
- Five character labels starting with the letter "o", in the form ".Oxxxx", are used by the COMPARE command. Any labels of this form can cause unpredictable highlighting results.