|
From: | Andy Stewart |
Subject: | Re: elisp-index-search on current word |
Date: | Wed, 08 Oct 2008 22:21:26 +0800 |
User-agent: | Gnus/5.13 (Gnus v5.13) Emacs/23.0.60 (gnu/linux) |
Kevin Rodgers <kevin.d.rodgers@gmail.com> writes: > Xah wrote: >> when i do elisp-index-search, is there a way to make the default >> choice the symbol the cursor is on? > > (defadvice elisp-index-search (before interactive-default activate) > "Provide the symbol at point as the default when reading TOPIC > interactively." > (interactive (list (read-string "Topic: " nil nil (thing-at-point > 'symbol))))) (defun elisp-index-search+ () "Look up TOPIC in the indices of the Emacs Lisp Reference Manual." (interactive) (let (topic) (setq topic (read-string (concat "Subject to look up: ") nil nil (symbol-name (symbol-at-point)))) (funcall 'switch-to-buffer-other-window nil) (info "elisp") (Info-index topic))) Regards. -- Andy.
[Prev in Thread] | Current Thread | [Next in Thread] |