Unix and Linux Discussions Tagged with pattern matching |
|
Thread / Thread Starter |
Last Post |
Replies |
Views |
Forum |
|
|
|
3 |
6,343 |
UNIX for Beginners Questions & Answers |
|
|
|
3 |
1,930 |
UNIX for Beginners Questions & Answers |
|
|
|
5 |
6,891 |
UNIX for Beginners Questions & Answers |
|
|
|
2 |
5,023 |
UNIX for Beginners Questions & Answers |
|
|
|
4 |
4,401 |
UNIX for Beginners Questions & Answers |
|
|
|
3 |
1,552 |
Shell Programming and Scripting |
|
|
|
6 |
1,293 |
Shell Programming and Scripting |
|
|
|
9 |
2,880 |
Shell Programming and Scripting |
|
|
|
5 |
12,825 |
UNIX for Beginners Questions & Answers |
|
|
|
3 |
1,576 |
Shell Programming and Scripting |
|
|
|
3 |
2,387 |
Shell Programming and Scripting |
|
|
|
5 |
14,223 |
UNIX for Dummies Questions & Answers |
|
|
|
6 |
6,964 |
UNIX for Dummies Questions & Answers |
|
|
|
4 |
3,191 |
Shell Programming and Scripting |
|
|
|
4 |
2,971 |
Shell Programming and Scripting |
|
|
|
8 |
8,155 |
Shell Programming and Scripting |
|
|
|
2 |
1,848 |
Shell Programming and Scripting |
|
|
|
3 |
7,226 |
Shell Programming and Scripting |
|
|
|
1 |
5,024 |
UNIX for Dummies Questions & Answers |
|
|
|
7 |
3,279 |
Shell Programming and Scripting |
|
|
|
3 |
7,050 |
Shell Programming and Scripting |
|
|
|
5 |
6,893 |
Shell Programming and Scripting |
|
|
|
2 |
8,864 |
Shell Programming and Scripting |
|
|
|
2 |
8,453 |
UNIX for Dummies Questions & Answers |
|
|
|
3 |
4,766 |
UNIX for Advanced & Expert Users |
|
|
|
9 |
10,894 |
Shell Programming and Scripting |
|
|
|
7 |
21,023 |
Shell Programming and Scripting |
|
|
|
3 |
2,882 |
Shell Programming and Scripting |
|
|
|
0 |
6,205 |
UNIX for Advanced & Expert Users |
|
|
|
9 |
73,947 |
Shell Programming and Scripting |
|
|
|
2 |
3,904 |
Shell Programming and Scripting |
|
|
|
1 |
6,180 |
Shell Programming and Scripting |
|
|
|
6 |
2,646 |
Shell Programming and Scripting |
|
|
|
0 |
2,231 |
Programming |
|
|
|
0 |
3,088 |
UNIX for Advanced & Expert Users |
|
|
|
0 |
2,265 |
UNIX for Dummies Questions & Answers |
|
|
|
7 |
3,414 |
Shell Programming and Scripting |
|
|
|
1 |
1,832 |
Shell Programming and Scripting |
|
|
|
3 |
2,717 |
UNIX and Linux Applications |
|
|
|
2 |
2,206 |
Shell Programming and Scripting |
MatchEditor(3I) InterViews Reference Manual MatchEditor(3I)
NAME
MatchEditor - StringEditor with pattern matching
SYNOPSIS
#include <InterViews/matcheditor.h>
DESCRIPTION
MatchEditor is a StringEditor subclass that checks the validity of its contents against a specified pattern. It is suitable for entering
strings that must conform to a particular format such as a number or a file name. The matching pattern is specified according to the rules
of scanf(3). For example, a pattern of "%3d" will match a 3-digit integer, a pattern of "%[ab]" will match a string containing only a's
and b's, and a pattern of "(%f, %f)" will match the string "(12.0, 5E23)".
PUBLIC OPERATIONS
MatchEditor(ButtonState*, const char* sample, const char* done)
Create a new MatchEditor object. The ButtonState, sample string, and termination string are passed to the StringEditor constructor.
void Match(const char* pattern, boolean keystroke = true)
Specify the pattern to match against. When MatchEditor performs matching, it will highlight any trailing part of the edit string
that does not conform to pattern. The user can then correct the string. If keystroke is true, matching will occur on every key-
stroke; otherwise matching will only occur on the completion of the edit. The initial pattern matches any string, and the initial
value of keystroke is true.
RESTRICTIONS
MatchEditor uses sscanf internally to check the pattern match. Different versions of sscanf have different scanning capabilities; check
with your local version to see what patterns you can use.
SEE ALSO
StringEditor(3I)
InterViews 7 Dec 1989 MatchEditor(3I)