all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* Convert an existing keyboard macro to elisp code?
@ 2012-08-03 15:10 Thorsten Jolitz
  2012-08-03 16:33 ` PJ Weisberg
                   ` (2 more replies)
  0 siblings, 3 replies; 8+ messages in thread
From: Thorsten Jolitz @ 2012-08-03 15:10 UTC (permalink / raw)
  To: help-gnu-emacs


Hi List, 

I cite from the http://www.emacswiki.org/emacs/KeyboardMacrosTricks
page, where somebody posted exactly the same question that came to my
mind today: 

,-------------------------------------------------------------------
| Is there a way to convert an existing keyboard macro to elisp code?
|
| You can do this with M-x insert-kbd-macro but the result is
| probably not to your liking. If I do:
| 
|  C-x (
|  C-n
|  foo
|  C-x )
|  M-x name-last-kbd-macro RET newline-and-foo
|  M-x insert-kbd-macro RET newline-and-foo RET
| 
| emacs will insert the following into the buffer:
| 
|  (fset 'newline-and-foo
|    "\C-nfoo")
| 
| I would very much like to be able to insert something like this:
| 
|   (defun newline-and-foo ()
|     (interactive)
|     (next-line)
|     (insert "foo"))
| 
| But it appears emacs does not have this feature.
`-------------------------------------------------------------------

Unfortunately, the answer was more a less a 'NO'(or 'YOU HAVE TO WRITE
IT YOURSELF').

Since Emacs is a pretty dynamic project, I thought I give it another try
on the mailing list - maybe this feature request has been implemented in
the meantime by somebody?

-- 
cheers,
Thorsten





^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2012-08-04 16:51 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-08-03 15:10 Convert an existing keyboard macro to elisp code? Thorsten Jolitz
2012-08-03 16:33 ` PJ Weisberg
2012-08-03 17:00   ` Yuri Khan
2012-08-03 18:16   ` Thorsten Jolitz
2012-08-04  6:13   ` Andreas Röhler
     [not found] ` <mailman.6259.1344011630.855.help-gnu-emacs@gnu.org>
2012-08-04  9:48   ` Raffaele Ricciardi
2012-08-04 16:39     ` Thorsten Jolitz
2012-08-04 16:51 ` Suvayu Ali

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.