RegExp runrev docu and extended features for pattern matching

runrev at animabit.de runrev at animabit.de
Tue Mar 24 06:48:19 EDT 2009


Hello,

for a project I need all the power of RegExp runrev can offer. Does anyone have an extended docu of the regexp usage in runrev at hand?

In the docu within the runrev IDE (try matchtext) I found the necessary
[0-9a-zA-Zäöü ...] for making regexp like
get matchText(line,"([0-9]+.[0-9]+).? m² .* ([0-9]+.[0-9]+) .?m² .* ([0-9]+.[0-9]+) .?m²",house,garden,fields)
and the link to
http://www.pcre.org/man.txt
=> runrev regexp try to be as Perl regexp conform as possible

From
http://www.mail-archive.com/metacard@lists.runrev.com/msg07768.html
I learned, that the character ?
can be used as a modifier for the regexp to search the smallest string for the searched pattern (instead of the widest)

from Perl I learned that 
\t means tab, 
\n cr 
\d digit = [0-9]
\D nondigit 
\w any char
\s whitespace char
\S non-whitespace char

and with the regexpbuilder I can test this.

\w+ \w+ \w+ 
results in 3 Words

\d{5}
means exactly five digits like in perl
\d{3,5} means 3 to 5 digits like in Perl
In the docu of matchtext:
If you need to make a case-insensitive comparison, use "(?i)" at the start of the regularExpression to make the match case-insensitive.
(?i) = case sensitive like /i in Perl
In Perl are modifiers /s /m and x for string, multiple lines and extended. Are these supported too but not documented?
Can I use (?(condition)yes-pattern|no-pattern) like in perl with x modifier?

Any suggestions appreciated ... or a link to a FAQ I did not find.

Regards,

Mit freundlichen Grüßen
Franz Böhmisch

boehmisch at animabit.de
http://www.animabit.de
GF Animabit Multimedia Software GmbH
Am Sonnenhang 22
D-94136 Thyrnau
Tel +49 (0)8501-8538
Fax +49 (0)8501-8537



More information about the Use-livecode mailing list