<<< Date Index >>>     <<< Thread Index >>>

Re: special $reply_regexp ?



Takashi,

ok, I modified the mutt_which_case() to be:

    int mutt_which_case (const char *s)
    {
      mbstate_t mbstate;
      int len = strlen(s);
      wchar_t wc;

      mbsinit(&mbstate);

      while (len>0)
      {
        int r = mbrtowc(&wc, s, len, &mbstate);
        s+=r; len-=r;
        if (r <= 0 || (isalpha(wc) && isupper(wc))) { 
          return 0; /* case-sensitive */
        }
      }
      return REG_ICASE; /* case-insensitive */
    }

which helped the latin expressions, but now russian expression wouldn't
match any case, as included GNU regex is not i18n'ed, as I understand.
I'll try with Solaris regex, but I remember there were problems with
some regex matching for quotation for example, when I used it last time...

Thanks,
    Pawel.

On Thu, Dec 01, 2005 at 09:59:53AM +0900, TAKAHASHI Tamotsu wrote:
>
>* Wed Nov 30 2005 Pawel S. Veselov <Pawel.Veselov@xxxxxxx>
>> ^(re|ответ([\\[0-9\\]+])*|aw):[ \t]*
>> 
>> it only matches the exact case, so I had to add all possible case
>> combinations into the regexp
>> 
>> Couldn't find any special treatment for the reply_regexp RX ...
>
>Maybe mutt_which_case() in pattern.c.
>
>HTH
>-- 
>tamo

Bye.
--
 Pawel S. Veselov [vps], Sun Microsystems, Inc.
 Staff Engineer, Java Mobile Systems and Services Engineering __ __(O) _ __
   (408) 276-5410   e-mail: Pawel.Veselov@xxxxxxx             \ V /| || '  \
fax(408) 276-6090 HomePage: http://manticore.2y.net            \_/ |_||_|_|_|