unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: Stefan Monnier <monnier@iro.umontreal.ca>
To: "Lennart Borgman \(gmail\)" <lennart.borgman@gmail.com>
Cc: 810@emacsbugs.donarmstrong.com
Subject: bug#810: 23.0.60; atomic-change-group narrowing problem
Date: Mon, 01 Sep 2008 22:38:48 -0400	[thread overview]
Message-ID: <jwv8wubqnmp.fsf-monnier+emacsbugreports@gnu.org> (raw)
In-Reply-To: <48BC6442.2060608@gmail.com> (Lennart Borgman's message of "Mon,  01 Sep 2008 23:53:06 +0200")

>>>>> When using atomic-change-group I got the message
>>>>> undo-more: Changes to be undone are outside visible portion of buffer
>>>>> The changes are also not undone. This seems wrong to me.
>>> 
>>>> The attached patch now also tries to restore any narrowing in force
>>>> before the atomic change.
>>> 
>>> I'm not sure we should do that.  Currently, narrowing operations are not
>>> saved to the undo-log, so making atomic-change-group save&restore the
>>> narrowing makes it behave differently from the undo.
>> 
>> I know what you mean but the present case is different.  When someone
>> uses narrowing within the atomic change group and we really want to undo
>> the changes (we still can decide that we won't fix the bug ;-)) we have
>> to widen the buffer.  If the buffer was narrowed _before_ entering the
>> atomic change group, it would be incorrect not to restore that.  Or am I
>> missing something?

The widening needs to be temporary around the call to undo, but that
doesn't seem to imply that atomic-change-group will preserve narrowing.


        Stefan






  reply	other threads:[~2008-09-02  2:38 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <48C3A6BE.8030305@gmx.at>
2008-08-28 18:58 ` bug#810: 23.0.60; atomic-change-group narrowing problem Lennart Borgman (gmail)
2008-08-28 21:26   ` martin rudalics
2008-08-28 21:37     ` Lennart Borgman (gmail)
2008-08-29  9:27       ` martin rudalics
2008-09-01 17:56   ` martin rudalics
2008-09-01 20:43     ` Stefan Monnier
2008-09-01 21:20       ` martin rudalics
2008-09-01 21:53         ` Lennart Borgman (gmail)
2008-09-02  2:38           ` Stefan Monnier [this message]
2008-09-07  9:37             ` martin rudalics
2008-09-02 14:13         ` Richard M. Stallman
2008-09-07 10:15   ` bug#810: marked as done (23.0.60; atomic-change-group narrowing problem) Emacs bug Tracking System

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

  List information: https://www.gnu.org/software/emacs/

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

  git send-email \
    --in-reply-to=jwv8wubqnmp.fsf-monnier+emacsbugreports@gnu.org \
    --to=monnier@iro.umontreal.ca \
    --cc=810@emacsbugs.donarmstrong.com \
    --cc=lennart.borgman@gmail.com \
    /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 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).