emacs-devel
[Top][All Lists]
Advanced

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

Re: Is it safe to use the combine-after-change-calls like this?


From: Stefan Monnier
Subject: Re: Is it safe to use the combine-after-change-calls like this?
Date: Wed, 17 Apr 2019 14:28:08 -0400
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (gnu/linux)

> 1. When multiple-cursors activates, set combine-after-change-calls to t
> 2. Edit the buffer with multiple active cursors
> 3. Before multiple-cursors deactivates, call combine-after-change-execute
> and set combine-after-change-calls back to nil.

As for the subject's question: I think it might be safe, but it probably
won't make a difference: combine-after-change-calls is ignored when
before-change-functions is non-nil.

Also, regarding interaction with non-CC-mode buffers: you might be able
to improve the efficiency of the code by executing the command of the
various cursors starting with the one closest to point-max and finishing
with the one closest to point-min.

For CC-mode buffers I have more trouble guessing if such an ordering
would also help, or would hurt, or make no difference.


        Stefan




reply via email to

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