Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Eclipse Platform » Question regarding use of regular expressions in find/replace
Question regarding use of regular expressions in find/replace [message #270649] Wed, 08 September 2004 18:04 Go to next message
David Whiteman is currently offline David WhitemanFriend
Messages: 166
Registered: July 2009
Senior Member
I don't know if this is the correct newsgroup for this question, but I
am having trouble using the reg ex support in the File find & replace.
I entered a find pattern of:

Draw[a-zA-Z0-9]+[(]

and I basically want to change all such occurrences to begin with a
lowercase d. I tried the following as the replace string and nothing
really happened in the file:

\l$

I admit I'm pretty new to regular expressions, but this seems to be the
correct approach based on what I've read. The ctrl+space help doesn't
really help.

Thanks,
David
Re: Question regarding use of regular expressions in find/replace [message #270865 is a reply to message #270649] Thu, 09 September 2004 16:35 Go to previous message
Eclipse UserFriend
Originally posted by: daniel.megert.gmx.net

David Whiteman wrote:

> I don't know if this is the correct newsgroup for this question, but I
> am having trouble using the reg ex support in the File find & replace.
> I entered a find pattern of:
>
> Draw[a-zA-Z0-9]+[(]
>
> and I basically want to change all such occurrences to begin with a
> lowercase d. I tried the following as the replace string and nothing
> really happened in the file:
>
> \l$
>
> I admit I'm pretty new to regular expressions, but this seems to be
> the correct approach based on what I've read. The ctrl+space help
> doesn't really help.

My Ctrl+Space help tells me to use
- (U) to mark U as capturing group
- \i in the Find field to refer to the capturing group number i
- $i in the Replace With field to refer to the capturing group number i

In your scenario you would use (...) to declare a group in the Find
field and $1 in the Replace With field to refer to the first group.

HTH
Dani

>
> Thanks,
> David
Previous Topic:netBeans
Next Topic:how to set CVS checked out projects to be java projects
Goto Forum:
  


Current Time: Wed Sep 18 18:18:42 GMT 2024

Powered by FUDForum. Page generated in 0.03743 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top