Replace Character [ HP EDIT Reference Manual ] MPE/iX 5.0 Documentation
HP EDIT Reference Manual
Replace Character
Purpose
Enables a user to delete and insert new text on a line.
Default Syntax
[n] r
where n is a count that represents the number of characters to delete
before entering Text Entry mode. The default value of n is 1.
Description
This command combines the functions of the Delete Character and Insert
Character commands. HP EDIT deletes a character or characters beginning
at the cursor position and places HP EDIT in Text Entry mode, enabling
you to insert text.
All of the original text beginning at the insert location shifts to the
right when you enter text. Consequently, if there is insufficient blank
space to insert text or to fit the original text, HP EDIT wraps the
excess text onto the next line.
Procedure
[REV BEG]
To replace a character:[REV END]
1. Move the cursor to the character or blank space to be replaced.
2. Press the [REV BEG]r[REV END] key. HP EDIT deletes the character
or blank space and places HP EDIT in Text Entry mode.
3. Insert one or more characters as needed. HP EDIT inserts the new
text and shifts the original text to the right.
4. Press / and Return when you have finished replacing text to return
to Command mode.
[REV BEG]
To replace a block of characters:
1. Select a block of text.
2. Press the r key. HP EDIT deletes the block of characters and
places HP EDIT in Text Entry mode.
3. Insert replacement text. HP EDIT shifts the existing text to the
right.
4. Press / and Return when you have finished replacing text to return
to Command mode.
[REV END]
Example
To replace the following cursor character:
Replace character A with character B.
1. Move the cursor to the position shown above and press the r key.
HP EDIT deletes the letter A, places HP EDIT in Text Entry Mode,
and moves the cursor as shown:
Replace character _with character B.
2. Type B and press / and Return to return to Command mode. HP EDIT
inserts the text as shown:
Replace character B with character B.
Related Commands
Append Line
Append To Character
Append To End Of Line
Append To Word
Delete Character
Delete Line
Delete Pattern
Delete Word
Insert Character
Insert Lines
Replace Line
Replace Word
MPE/iX 5.0 Documentation