GNU bug report logs - #75931
31.0.50; mouse-face and pointer properties make pointer change back and forth

Previous Next

Package: emacs;

Reported by: Mauro Aranda <maurooaranda <at> gmail.com>

Date: Wed, 29 Jan 2025 18:23:01 UTC

Severity: normal

Found in version 31.0.50

Done: Eli Zaretskii <eliz <at> gnu.org>

Bug is archived. No further changes may be made.

Full log


Message #35 received at 75931 <at> debbugs.gnu.org (full text, mbox):

From: Eli Zaretskii <eliz <at> gnu.org>
To: Mauro Aranda <maurooaranda <at> gmail.com>
Cc: luangruo <at> yahoo.com, 75931 <at> debbugs.gnu.org
Subject: Re: bug#75931: 31.0.50; mouse-face and pointer properties make
 pointer change back and forth
Date: Thu, 30 Jan 2025 14:25:13 +0200
> Date: Thu, 30 Jan 2025 09:05:23 -0300
> Cc: 75931 <at> debbugs.gnu.org, Po Lu <luangruo <at> yahoo.com>
> From: Mauro Aranda <maurooaranda <at> gmail.com>
> 
> On 30/1/25 08:36, Eli Zaretskii wrote:
>  >> Perhaps it is the call to show_mouse_face that was added to
>  >> erase_phys_cursor.
>  >
>  > Yes, I think so.  If you arrange for that call to show_mouse_face to
>  > not redefine the mouse cursor near the end of show_mouse_face, does
>  > the problem go away? or do you still need to revert those two lines in
>  > dispnew.c added by my changes?
> 
> I've no idea how to do that.  So, I did something silly:
> In show_mouse_face, when draw is DRAW_MOUSE_FACE, I changed:
> FRAME_OUTPUT_DATA (f)->hand_cursor
> to:
> FRAME_OUTPUT_DATA (f)->current_cursor

That's what I had in mind, thanks.

> With that change, I don't need to revert the changes in dispnew.c.

Good, so we now need to arrange that this particular call to
show_mouse_face doesn't touch the mouse cursor shape.  Let's see what
Po Lu says about that.  If he agrees that there's no need to redefine
the cursor in this particular call of show_mouse_face, the technical
solution is simple.

> But I'm way out of my league here, so I don't know if the change is
> correct, most probably not.  What seems correct is not specifying
> hand_cursor, but rather find out which cursor do we need to draw when
> redrawing it...

That'd be the fallback plan, but it would require to refactor the code
in note_mouse_highlight, and in particular move the code which
determines the pointer shape into show_mouse_face (which will make it
more expensive), and also other changes, since show_mouse_face is
called from several places.  Let's hope this will not be necessary.




This bug report was last modified 108 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.