[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug#10885: Replace expressions: enhance functionality when searching in
From: |
Glenn Morris |
Subject: |
bug#10885: Replace expressions: enhance functionality when searching in filled paragraphs |
Date: |
Sat, 25 Feb 2012 20:57:05 -0500 |
User-agent: |
Gnus (www.gnus.org), GNU Emacs (www.gnu.org/software/emacs/) |
linuxfever wrote:
> Currently it seems that when trying to replace an expression comprising two
> words, say for example 'replace this', then the functions 'replace-string'
> or 'replace-regexp' fail to locate the expression when that is split along
> two lines in the text, i.e., in the above example when the word 'replace' is
> at the end of one line, and the word 'this' is at the beginning of the next
> one.
You can use query-replace-regexp for this.
Sample input:
This is text. This is text. This is text. This is text. Replace this.
This is text. This is text. This is text. This is text. This is text. Replace
this.
Replace this.
M-x query-replace-regexp RET \(replace\)\([ ^I^J]*\)\(this\) RET Done\2that RET
Output:
This is text. This is text. This is text. This is text. Done that.
This is text. This is text. This is text. This is text. This is text. Done
that.
Done that.
- bug#10885: Replace expressions: enhance functionality when searching in filled paragraphs, linuxfever, 2012/02/25
- bug#10885: Replace expressions: enhance functionality when searching in filled paragraphs,
Glenn Morris <=
- bug#10885: Replace expressions: enhance functionality when searching in filled paragraphs, Kevin Rodgers, 2012/02/26
- bug#10885: Replace expressions: enhance functionality when searching in filled paragraphs, Dani Moncayo, 2012/02/28
- bug#10885: Replace expressions: enhance functionality when searching in filled paragraphs, Dani Moncayo, 2012/02/28
- bug#10885: Replace expressions: enhance functionality when searching in filled paragraphs, Juri Linkov, 2012/02/28
- bug#10885: Replace expressions: enhance functionality when searching in filled paragraphs, Glenn Morris, 2012/02/28
- bug#10885: Replace expressions: enhance functionality when searching in filled paragraphs, Juri Linkov, 2012/02/28
bug#10885: Replace expressions: enhance functionality when searching in filled paragraphs, linuxfever, 2012/02/26
bug#10885: Replace expressions: enhance functionality when searching in filled paragraphs, Dani Moncayo, 2012/02/26