Re: regular expression and speech dic


Mr. Wong Chi Wai, William <cwwong.pro@...>
 

But, I don't understand why mine regular expression  rule didn't work.
lv[^a-z]
where "lv" has no problem.
"[]" is to match the ^a-z in a group; where ^a-z is to match anything except a-z.
so, the rule is intended to match any "lv" that is not follow by any letters.
However, it turn out that if the rule is replace by "level"
say lv12 should read as level 1 2;but, it reads level 2 and missed the number 1.
if it is lv2, it reads only "level" and missed the number 2.

I don't understand what is wrong with my rule.
Thanks.
William

Join nvda@nvda.groups.io to automatically receive all group messages.