|
Re: Question regarding use of regular expressions in find/replace [message #270865 is a reply to message #270649] |
Thu, 09 September 2004 16:35 |
Eclipse User |
|
|
|
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
|
|
|
Powered by
FUDForum. Page generated in 0.04663 seconds