From: "Drew Adams" <drew.adams@oracle.com>
Subject: RE: replace-string for 1 line
Date: Thu, 17 Aug 2006 09:35:25 -0700 [thread overview]
Message-ID: <DNEMKBNJBGPAOPIJOOICCEEKDIAA.drew.adams@oracle.com> (raw)
In-Reply-To: <5853003.post@talk.nabble.com>
Say I want to carry out a replace command, but just for 1 line
and not the rest of the docuemnt, is there a way to do that?
If you use transient-mark-mode (I recommend it), then just select the line,
then do the replacement. Many other commands and functions also operate on
the region, if it is active.
If you don't use transient-mark-mode, then narrow to that line: Select the
line, then `C-x n n'. Then do your replacement - only the region is visible,
so only the region is affected. Use `C-x n w' to widen, afterward. To do
this in Emacs Lisp, use `narrow-to-region' and `widen'.
next prev parent reply other threads:[~2006-08-17 16:35 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-08-17 15:07 replace-string for 1 line ld1976
2006-08-17 16:35 ` Drew Adams [this message]
[not found] <mailman.5278.1155831504.9609.help-gnu-emacs@gnu.org>
2006-08-17 16:38 ` B. T. Raven
2006-08-17 16:40 ` Pascal Bourguignon
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=DNEMKBNJBGPAOPIJOOICCEEKDIAA.drew.adams@oracle.com \
--to=drew.adams@oracle.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.