Search for Regular Expressions

Top  Previous  Next

The text editor supports "regular expressions," which can be used to search for special cases of text strings. Regular expressions contain the control characters in the search argument string:

?                              Means any one character in this place. Example: if you specify ?ell as the search string, then "bell," "tell," "cell," etc. will be found.

%                             Means the beginning of line. The characters following '%' must begin from column 1. Example: %Counter - find the word "Counter," which begins at the first column.

$                               The end of line. The characters preceding the '$' should be at the last positions of the line. Example: Counter$ - find the word "Counter" at the line end.

@                             Match the next character literally; '@' lets you specify the control characters as usual letters. Example: @? - search for the question mark character.

\xNN                       The hexadecimal value of the character. Example: \xA7 - find the character with the hexadecimal code of A7.

+                               Indefinite number of repetitions of the previous character. For example, if you specify 1T+2, then the editor will find the lines containing "1" followed by "2", which are separated with any number of repetitions of the letter T.

[c1-c2]                   Match any character in the interval from c1 to c2. Example: [A-Z] means any letter from A to Z.

[~c1-c2]                Match any character whose value is outside the interval from c1 to c2. Example: [~A-Z] means any character except for the uppercase letters.

text1|text2           The "|" character is the logical "OR" and the editor will look for either text1 or text2. Example: LPT|COM|CON means search for "LPT" or "COM" or "CON."