User-defined wild cards, Σ] (any character from a set σ excluding return), Σ] (any character not from a set σ) – Nisus Writer Express User Manual

Page 217: Characters with a unique match, Any character from a set ∑ excluding return), Any character not from a set ∑)

Advertising
background image

Polishing & Managing Documents

197

[^[:alpha:]_]

Finds any non-alphabetic character excluding the underscore character “_” (ASCII
95

_

).

[[blank]]

Finds either a space (ASCII (Unicode) 32) or a tab (ASCII (Unicode) 9); same as [\s
\t]
.

\d

Finds any digit from 0 through 9; same as menu command AnyDigit ([0-9])from
the Wild Card menu.

[[:xdigit:]]

Finds any digit or alphabetic character from a to f; covers the ranges 0-9 a-f A-F;
use to find hexadecimal numerals.

[[:lower:]]

Finds any lowercase alphabetic character from a to z plus modified alphabetics;
the equivalent of the command LowercaseLetter ([a-z])in the Wild Card menu.

[[:alnum:]]

Finds any alphanumeric character; the equivalent of the command
AnyLetterOrDigit ([A-Za-z0-9]) in the Wild Card menu.

\w

Finds any alphanumeric, underscore character; same as [[:alnum:]] but includes
the underscore character.

[[:upper:]]

Finds any uppercase alphabetic character in the range A to Z; the equivalent of
the command UppercaseLetter ([A-Z])in the Wild Card menu.

\W

Finds any non-alphanumeric character (excluding a Return and an underscore);
opposite of \w.

[[:punct:]]

Finds any “punctuation” character such as ( [ { “ ‘ . , ; : / - _ @ # % & * \ ? ! ’ ” } ] ).

User-defined Wild Cards

PowerFind Pro also allows the user to define wild cards.
There are two ways to define wild cards. One way is to list all the characters that the wild card
matches between brackets []. For example, the expression [abc] is a wild card that matches any of
the three letters a, b, or c and nothing else.
Another way is to list all the characters the wild card does not match between brackets and a caret
[^]. Here the caret means “not in the set.” For example, [^abc] is a wild card that finds any
character that is not a, b, c, or Return. To include the Return character in the set, enter a colon in
front of the opening bracket.

[∑]

(any character from a set ∑ excluding Return)

[∑] can define a range, an enumerated set, or a combination of both. To define a range use a
hyphen “-” between the start of the range and the end of the range. For example, the wild card [a-f]
represents any character in the alphabetic range from a through f. If you use the bracket to define a
set that includes any digit, you cannot use \d, but must type 0-9 between the brackets. The range
assumes the order of increasing ASCII (Unicode) codes. Enter the hexadecimal representation for
space \x20.
Be sure to uniquely define each specified character, which means you cannot use certain wild
cards. A backslash \ preceding any other character causes Nisus Writer Express to interpret the
character literally. For example, to use the six characters , ], [, -, ^ and \ in a set begin the string
with \. Enter \ twice to include the \ character itself.
Nisus Writer Express interprets all characters inside the brackets [] literally. For example, a search
for [:a] matches a colon or an a.

[^∑] (any character not from a set ∑)

[^∑] finds any character not in the set . For example, [^a-z] finds any character not a lowercase
alphabetic and the pattern [^!-~] finds any character whose ASCII (Unicode) code is not in the
range 33 to 126. A particularly useful application of this metacharacter is for finding columns of
text; the expression [^\t]+\t finds anything that is not a tab (which appears one or more times)
followed by a tab.

Characters with a Unique Match

These metacharacters usually match a character that does not print. Because these characters are
a unique match, you can use them in Find and Replace expressions.

Character

Finds

\0 (null)

Null character (ASCII (Unicode) code 0)

\b

Backspace character (ASCII (Unicode) code 8)

\t

Tab character (ASCII (Unicode) code 9); press

1 @ to insert an actual tab

character in an expression

Advertising