all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: "Chandler, John" <jchandler@cfa.harvard.edu>
To: Lars Ingebrigtsen <larsi@gnus.org>
Cc: 16181@debbugs.gnu.org
Subject: bug#16181: 23.1; losing track of point
Date: Sun, 30 May 2021 15:23:39 -0400	[thread overview]
Message-ID: <CAOHbs5cRX6w_axNHWfMgW1D6cmODkhVFuU5Wa8hMZznb09Nzqg@mail.gmail.com> (raw)
In-Reply-To: <87a6oc4wrw.fsf@gnus.org>

On Sun, May 30, 2021 at 1:26 AM Lars Ingebrigtsen <larsi@gnus.org> wrote:
>
> John Chandler <chandler@cfa.harvard.edu> writes:
>
> > The following macro is a short example:
> >
> > (defun ttt() "add tag from start" (interactive)
> >   (save-excursion
> >     (goto-char 0)
> >     (copy-to-register 26 (point) (progn (forward-word 1)(point)) t))
> >   (insert-register 26)
> >   (forward-line 1))
> >
> > The file to be edited using this macro should begin with a line
> > containing a list of words to be inserted in front of a succession of
> > lines in the file.  If the lines in the file generally wrap,
> > especially if they wrap multiple times each, the successive
> > application of the macro should quickly trigger the bug.

The bug is intermittent and seems to depend on the exact alignment
of the display when (point) moves out of the current window.  I found
a 99% reliable workaround by inserting lots of (sit-for) invocations into
complicated macros.  For the same reason, the above macro triggers the
bug only if it is invoked multiple times within another macro, and not when
it's invoked by hand (except rarely).  Meanwhile, I see the bug still
happening in emacs 22.2.1 and 23.1.1, but apparently not in 24.3.1,
so I guess it's fixed.

John Chandler





  reply	other threads:[~2021-05-30 19:23 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-12-18  1:36 bug#16181: 23.1; losing track of point John Chandler
2014-02-26 20:31 ` bug#16181: 23.1; losing track of point - partial workaround Chandler, John
2021-05-30  5:26 ` bug#16181: 23.1; losing track of point Lars Ingebrigtsen
2021-05-30 19:23   ` Chandler, John [this message]
2021-05-31  5:44     ` Lars Ingebrigtsen

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=CAOHbs5cRX6w_axNHWfMgW1D6cmODkhVFuU5Wa8hMZznb09Nzqg@mail.gmail.com \
    --to=jchandler@cfa.harvard.edu \
    --cc=16181@debbugs.gnu.org \
    --cc=larsi@gnus.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

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

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.