To improve my scanty knowledge of elisp, I want to rewrite a macro as a
function. I can't get to first base on this. I think I can do this if
given links or keywords for the self-instruction of a noob.
For example I can't make out this:
(shell-command COMMAND &optional OUTPUT-BUFFER ERROR-BUFFER)
I can't find a reference on how to read this line.
The function should do this:
I put point on a word in text buffer. Then I hit a command
key, say C-l.
2.command key calls function that does this:
reads word into an accessible place as a string
shell-command "whitaker <put word string here>"
latin calls my latin-english dictionary
the output appears in the shell command buffer
3. I accomplised this with this keyboard macro:
;;look up latin words
(fset 'whitaker
[?\M-x ?c ?o ?p ?y ?- ?w ?o tab return ?\M-x ?s ?h ?e ?l tab ?- ?c ?o ?m ?m
tab return ?l ?a ?t ?i ?n ? ?\C-y return])
(global-set-key (kbd "C-l") 'whitaker)
The macro uses the function copy-word, borrowed from here:
http://www.emacswiki.org/emacs/CopyWithoutSelection
Thanks.
_______________________________________________
info-gnus-english mailing list
[email protected]
https://lists.gnu.org/mailman/listinfo/info-gnus-english