emacs-devel
[Top][All Lists]
Advanced

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

Re: Suggestion to add before and after hooks to posn-set-point.


From: Robert Weiner
Subject: Re: Suggestion to add before and after hooks to posn-set-point.
Date: Mon, 18 Sep 2017 23:07:11 -0400

On Mon, Sep 18, 2017 at 10:21 PM, Stefan Monnier <address@hidden> wrote:
> It seems as of Emacs 25, there are no hooks in posn-set-point to do
> something custom before or after point has been set/moved.

There are various ways to do things very similar to what posn-set-point
does, so a hook on this function seems rather odd to me: it will only
catch some window selections and some point movements.
​​
 
​​
IOW I find it difficult to characterize when these hooks will be run
​​
(except with the trivial characterization that they're run when
​​
posn-set-point is run, which is not very meaningful since no command is
​​
documented to use this function).

​FYI, the initial desire for these hooks came from wanting to do something whenever the mouse set point.
Then I thought it would be more useful if it covered any interactive setting of point, which led to posn-set-point
(called by mouse-set-point).  If there are better ways to do this, let's discuss them.

Bob​​

reply via email to

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