Post Reply 
More than one match/replace per filter?
Sep. 13, 2011, 09:37 PM (This post was last modified: Sep. 13, 2011 11:31 PM by zoltan.)
Post: #6
RE: More than one match/replace per filter?
OK, now I get most of it.
Before I can test, I'd like to understand example C better and be sure of the list entry. I see the sequence like this:

1.) Look for spaces or end of tag.
2.) if found, place in variable 2
3.) Look for a letter (of the word to be replaced)
at this point it's confusing because of the "&"
I know it means "AND" but it seems to be acting more as a conditional. "IF there's an a-z character, check the list" Is that true? And should the list entry be
"eins(^[a-z]) $SET(\1=one)" ?

I'm not sure what "(^(^[a-z]))" does differently or why it's superior to the above, since [a-z] didn't remove letters either. It seems to be nothing more than double negation, so why not just use "(\s|>)\2([a-z]$LST(Trans))"

EDIT:
After testing:
Code:
Match ="(\s|>)\2([a-z]&$LST(Trans))"
Replace = "\2\1"
List entry:  zwei(^[a-z]) $SET(\1=two)

words after parentheses are not matched
spaces after words are consumed, joining the replaced word with the next one.

I thought zwei(^[a-z])\3 $SET(\1=two\3)
might preserve the space after the match, but it doesn't.
Add Thank You Quote this message in a reply
Post Reply 


Messages In This Thread
RE: More than one match/replace per filter? - zoltan - Sep. 13, 2011 09:37 PM

Forum Jump: