From: "Andreas Röhler" <andreas.roehler@easy-emacs.de>
To: help-gnu-emacs@gnu.org
Subject: Re: keyboard macro syntax
Date: Sun, 13 Dec 2009 10:34:31 +0100 [thread overview]
Message-ID: <4B24B527.1060205@easy-emacs.de> (raw)
In-Reply-To: <87iqcd4dzy.fsf@ergodik.univ-brest.fr>
harven wrote:
> There seems to be two different syntaxes for keyboard macros,
> depending whether they are named using the commands
> name-last-kbd-macro or kmacro-name-last-macro e.g.
>
> (fset 'hello1
> [?\C-s ?h ?e ?l ?l ?o ?\C-m ?, ? ?w ?o ?r ?l ?d ?! ?\C-u ?\C- ])
>
> (fset 'hello2
> (lambda (&optional arg) "Keyboard macro." (interactive "p") (kmacro-exec-ring-item (quote ([19 104 101 108 108 111 13 44 119 111 114 108 100 33 21 67108896] 0 "%d")) arg)))
>
> Anyone knows why ?
>
> The first one is more readable but I suspect the second one is the preferred one
> since it is granted a keybinding (C-x C-k n).
>
Hi,
a more general remark: storing keyboard macros is useful for
simple tasks.
If you reach the point to edit your macro, it's
usually much faster to write your own functions. So far my experience.
Andreas
--
https://code.launchpad.net/s-x-emacs-werkstatt/
http://bazaar.launchpad.net/~a-roehler/python-mode/python-mode.el/
prev parent reply other threads:[~2009-12-13 9:34 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-12-11 17:28 keyboard macro syntax harven
2009-12-13 9:34 ` Andreas Röhler [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=4B24B527.1060205@easy-emacs.de \
--to=andreas.roehler@easy-emacs.de \
--cc=help-gnu-emacs@gnu.org \
/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.