From: "Drew Adams" <drew.adams@oracle.com>
To: "'acomber'" <deedexy@gmail.com>, <Help-gnu-emacs@gnu.org>
Subject: RE: Use text in emacs buffer to populate command window
Date: Mon, 18 Feb 2013 10:41:46 -0800 [thread overview]
Message-ID: <A75F3FEAF8494244BEE85E3B07A870F8@us.oracle.com> (raw)
In-Reply-To: <1361211922783-278645.post@n5.nabble.com>
> If I run a search in emacs I can C-s then c-w repeatedly to
> search for text under the current cursor position. But if I use
> a diffierent command I can't always use C-w. eg I use m-x
> highlight-regexp I want to also grab the text under the cursor.
> How do I do that?
If the command itself doesn't provide something at point as a default value
(retrievable using `M-n') then you're out of luck at that point.
But:
1. You can of course select the text you want to inser first, before invoking
the command that reads input, then use `C-y' when the command prompts you for
input.
2. If you use Icicles, then you can _always_ grab text at or near the cursor and
insert it in the minibuffer, using `M-.'.
http://www.emacswiki.org/emacs/Icicles_-_Inserting_Text_from_Cursor
You can configure what `M-.' does, including what kinds of things it can insert
and whether successive `M-.' should insert successive things of the same kind
(like `C-w' does for Isearch) or cycle among different kinds of thing.
prev parent reply other threads:[~2013-02-18 18:41 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-02-18 18:25 Use text in emacs buffer to populate command window acomber
2013-02-18 18:37 ` Jambunathan K
2013-02-18 18:43 ` Jambunathan K
2013-02-18 18:47 ` acomber
2013-02-18 18:54 ` Drew Adams
2013-02-18 18:41 ` Drew Adams [this message]
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=A75F3FEAF8494244BEE85E3B07A870F8@us.oracle.com \
--to=drew.adams@oracle.com \
--cc=Help-gnu-emacs@gnu.org \
--cc=deedexy@gmail.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.