emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Old-style backquotes in cc-vars.el


From: Juri Linkov
Subject: Re: Old-style backquotes in cc-vars.el
Date: Thu, 06 Sep 2007 17:27:37 +0300
User-agent: Gnus/5.11 (Gnus v5.11) Emacs/23.0.50 (gnu/linux)

>     I did it with a macro that did something like:
>
>        C-u C-s ([`,address@hidden C-SPC M-x up-list RET DEL C-u C-SPC C-d 
> C-SPC C-M-u C-d
>        C-u C-SPC
>
> Could you work out the details again, and put it in NEWS as a
> suggestion?  Or code it in Lisp?

BTW, since TODO contains the following task:

    ** Add a way to convert a keyboard macro to equivalent Lisp code.

I've implemented a feature that converts a macro like:

    C-u C-s ([`,address@hidden C-SPC M-x up-list RET DEL C-u C-SPC C-d C-SPC 
C-M-u C-d
    C-u C-SPC

to the equivalent Lisp function:

(defun last-macro-commands ()
  (interactive)
  (re-search-forward "([`,address@hidden")
  (set-mark-command nil)
  (up-list 1)
  (backward-delete-char-untabify 1)
  (pop-to-mark-command)
  (delete-char 1)
  (set-mark-command nil)
  (backward-up-list)
  (delete-char 1)
  (pop-to-mark-command))

I need to polish details and will post a patch asap.

-- 
Juri Linkov
http://www.jurta.org/emacs/




reply via email to

[Prev in Thread] Current Thread [Next in Thread]