help-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: search for any two consecutive uppercase characters


From: doitian
Subject: Re: search for any two consecutive uppercase characters
Date: Thu, 13 Aug 2009 20:50:08 -0700 (PDT)
User-agent: G2/1.0

On Aug 13, 7:11 am, "A.Politz" <poli...@googlemail.com> wrote:
> On Aug 13, 12:38 am, p...@informatimago.com (Pascal J. Bourguignon)
> wrote:
>
> > There is no
> > [:upper:] in emacs regular expressions.
>
> That' actually not true, as described here
> (info "(elisp)Char Classes")
>
> -ap

Yes, [:upper:] is available. A common error is using it directly.
Indeed, it must be put in a char class like [[:upper:]].

The problem can be solved using query-replace-regexp

Search Pattern: \<[[:upper:]]\{2,\}\>
Replace:  \,(capitalize \&)


reply via email to

[Prev in Thread] Current Thread [Next in Thread]