help-gnu-emacs
[Top][All Lists]
Advanced

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

Re: Indenting paragraphs manually


From: Le Wang
Subject: Re: Indenting paragraphs manually
Date: Mon, 7 Mar 2011 22:38:37 +0800

On Mon, Mar 7, 2011 at 9:42 PM, Le Wang <address@hidden> wrote:
On Mon, Mar 7, 2011 at 4:18 PM, Teemu Likonen <address@hidden> wrote:

...
 
 (let ((repeat-message-function #'ignore))
   (setq last-repeatable-command #'tl-indent-region-engine)
   (repeat nil)))


Wow, this repeat bit is a /COOL/ trick.  I'll have to file this snippet away.  Region stays active, and deactivates when repeating stops (no mucking with deactivate-mark manually) ... very cool.

Thanks for sharing!

Teemu, one bug in the code is that you need to call (require 'repeat) at the beginning, otherwise when it gets autoloaded later `repeat-message-function' doesn't get initialized properly because of the "(let ..." binding.


--
Le

reply via email to

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