unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
* bug#22537: 25.1.50; cursor-sensor-mode strangeness
@ 2016-02-02 21:20 Helmut Eller
  2020-12-03  9:49 ` Lars Ingebrigtsen
  0 siblings, 1 reply; 2+ messages in thread
From: Helmut Eller @ 2016-02-02 21:20 UTC (permalink / raw)
  To: 22537

When executing the example below with: emacs -Q -nw -l test.el
Emacs prints
   "result: ((1 2 entered) (5 6 left))"
I would expect this instead:
   ((1 2 entered) (2 3 left) (4 5 entered) (5 6 left))

(progn
  (defvar test-result '())

  (defun test-sensor (_ pos entered/left)
    (push (list pos (point) entered/left) test-result))

  (defun test ()
    (interactive)
    (setq test-result '())
    (with-current-buffer (get-buffer-create "test")
      (erase-buffer)
      (insert "x")
      (insert (propertize "a" 'cursor-sensor-functions (list #'test-sensor)))
      (insert "y")
      (insert (propertize "b" 'cursor-sensor-functions (list #'test-sensor)))
      (insert "z")
      (cursor-sensor-mode 1)
      (save-selected-window
	(let ((win (display-buffer (current-buffer))))
	  (select-window win)
	  (goto-char (point-min)))
	(while (not (eobp))
	  (redisplay t)
	  (forward-char))
	(redisplay t)))
    (message "result: %S" (reverse test-result)))

  (test))

In GNU Emacs 25.1.50.3 (i686-pc-linux-gnu, GTK+ Version 3.14.5)
 of 2016-01-29 built on ix
Repository revision: 487bd7aedf9bbbf0b939b653912253fbeb7d16b9
System Description:	Debian GNU/Linux 8.0 (jessie)

Configured using:
 'configure --with-jpeg=no --with-gif=no --with-tiff=no'

Configured features:
XPM PNG RSVG SOUND DBUS GSETTINGS NOTIFY LIBXML2 FREETYPE XFT ZLIB
TOOLKIT_SCROLL_BARS GTK3 X11

Important settings:
  value of $LANG: C.UTF-8
  locale-coding-system: utf-8-unix





^ permalink raw reply	[flat|nested] 2+ messages in thread

* bug#22537: 25.1.50; cursor-sensor-mode strangeness
  2016-02-02 21:20 bug#22537: 25.1.50; cursor-sensor-mode strangeness Helmut Eller
@ 2020-12-03  9:49 ` Lars Ingebrigtsen
  0 siblings, 0 replies; 2+ messages in thread
From: Lars Ingebrigtsen @ 2020-12-03  9:49 UTC (permalink / raw)
  To: Helmut Eller; +Cc: 22537

Helmut Eller <eller.helmut@gmail.com> writes:

> When executing the example below with: emacs -Q -nw -l test.el
> Emacs prints
>    "result: ((1 2 entered) (5 6 left))"
> I would expect this instead:
>    ((1 2 entered) (2 3 left) (4 5 entered) (5 6 left))

(This bug report unfortunately got no response at the time.)

In Emacs 28, I'm getting:

"result: ((1 2 entered) (2 3 left) (3 4 entered) (4 5 left))"

And I think that's correct?  So it looks like this has been fixed at
some point in the years that's passed since this was reported, and I'm
closing this bug report.

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no





^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2020-12-03  9:49 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-02-02 21:20 bug#22537: 25.1.50; cursor-sensor-mode strangeness Helmut Eller
2020-12-03  9:49 ` Lars Ingebrigtsen

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).