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

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

bug#50256: thing-at-mouse


From: Juri Linkov
Subject: bug#50256: thing-at-mouse
Date: Wed, 01 Sep 2021 19:25:15 +0300
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (x86_64-pc-linux-gnu)

>>   (with-current-buffer "*Messages*"
>>     (mouse-set-point last-input-event))
>>
>> and it moves point in *scratch* to the position of point of
>> the *Messages* buffer.
>
> I don't follow: what do you expect to be in last-input-event in this
> case, and how is that relevant to mouse clicks, when the mouse is not
> even involved in this scenario?

Normally, last-input-event should be a mouse click event.
But sometimes it gets a non-mouse event (e.g. a number).
Then in mouse-set-point, event-end produces a fake mouse event
using posn-at-point.  But such constructed event
contains position from a random buffer (that was current
at the time of invocation). It should contain the position
of point in the buffer displayed in the selected window.





reply via email to

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