View Single Post
Old 15th April 2004, 03:48   #44
TomyLobo
Major Dude
 
TomyLobo's Avatar
 
Join Date: Feb 2004
Location: Germany
Posts: 580
AVSTrans 1.12.00 is out
Most noticable new feature: Regular Expression Matching/Replacement .
I'm using the RegEx Object from VBScript for that.
For a description of the available Expressions look at the corresponding MSDN site.

The syntax is
code:

//$AVSTrans_Replacement_Pattern=pattern->replacevar


the replacevar may contain things like $1 to get the remembered matches described in the "(pattern)" line in the MSDN document.

a (working) example :
code:

//$AVSTrans_Replacement_Pattern=variable\(([^\)]*)\)->megabuf($1+n2)
a=b;
variable(ab)=d;
e=f


this translates to
code:

a=b;
assign(megabuf(ab+n2),d);
e=f

TomyLobo is offline   Reply With Quote