From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Davis Herring Newsgroups: gmane.emacs.devel Subject: Re: disabling undo boundaries Date: Fri, 07 Aug 2015 17:49:01 -0600 Organization: XCP-1 Message-ID: <55C543ED.5030801@lanl.gov> References: <87fv746rd5.fsf@newcastle.ac.uk> <87oalqrgm7.fsf@newcastle.ac.uk> <87ioby3tdy.fsf@newcastle.ac.uk> <87y4kth5ps.fsf@newcastle.ac.uk> <87sib0a3jr.fsf@newcastle.ac.uk> <871tiiowjw.fsf@newcastle.ac.uk> <87siaxk4dl.fsf@newcastle.ac.uk> <87iobsr6m2.fsf@newcastle.ac.uk> <87oalgaicm.fsf@newcastle.ac.uk> <87y4kkkzlo.fsf@newcastle.ac.uk> <87mw0zk7yp.fsf@newcastle.ac.uk> <87617mgp1b.fsf@newcastle.ac.uk> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit X-Trace: ger.gmane.org 1438993460 1788 80.91.229.3 (8 Aug 2015 00:24:20 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sat, 8 Aug 2015 00:24:20 +0000 (UTC) Cc: Phillip Lord , Emacs development discussions To: Stefan Monnier Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Sat Aug 08 02:24:11 2015 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1ZNrvm-0006Ek-DR for ged-emacs-devel@m.gmane.org; Sat, 08 Aug 2015 02:24:10 +0200 Original-Received: from localhost ([::1]:51560 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZNrvl-0003Lg-5F for ged-emacs-devel@m.gmane.org; Fri, 07 Aug 2015 20:24:09 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:59613) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZNrvZ-0003LP-17 for emacs-devel@gnu.org; Fri, 07 Aug 2015 20:23:58 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ZNrvV-0000rU-PM for emacs-devel@gnu.org; Fri, 07 Aug 2015 20:23:56 -0400 Original-Received: from proofpoint5.lanl.gov ([2001:400:4210:400::a5]:52453) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZNrvV-0000eY-Fa for emacs-devel@gnu.org; Fri, 07 Aug 2015 20:23:53 -0400 Original-Received: from mailrelay2.lanl.gov (mailrelay2.lanl.gov [128.165.4.103]) by mailgate5.lanl.gov (8.15.0.59/8.14.7) with ESMTP id t77Nn1XW012813; Fri, 7 Aug 2015 17:49:01 -0600 Original-Received: from localhost (localhost.localdomain [127.0.0.1]) by mailrelay2.lanl.gov (Postfix) with ESMTP id 861DEEB72D9; Fri, 7 Aug 2015 17:49:01 -0600 (MDT) X-NIE-2-Virus-Scanner: amavisd-new at mailrelay2.lanl.gov Original-Received: from xray-r08.lanl.gov (xray-r08.lanl.gov [128.165.123.189]) by mailrelay2.lanl.gov (Postfix) with ESMTP id 6CEEEEB72D7; Fri, 7 Aug 2015 17:49:01 -0600 (MDT) User-Agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.2.18) Gecko/20110717 Lanikai/3.1.11 In-Reply-To: X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10432:5.14.151, 1.0.33, 0.0.0000 definitions=2015-08-08_01:2015-08-07, 2015-08-07, 1970-01-01 signatures=0 X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address (bad octet value). X-Received-From: 2001:400:4210:400::a5 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:188591 Archived-At: [I'm late to this thread, but after reading the more recent portion, this still seems a useful reply.] > For self-insert-command, it's more tricky, and you'd probably need to do > the extra manual work. E.g. add a post-self-insert-hook which checks if > this self-insert-command removed the previous undo-boundary and then > remove it as well in the sibling buffer. I can't see how undo.c could > do that for you magically, since it doesn't know that the insertions in > the sibling buffer are "clones" of the insertions in the main buffer, > nor that it's done by self-insert-command. Another approach would be > for you to arrange such that your a-f-c uses self-insert-command rather > than `insert' when cloning the insertion from a self-insert-command, but > that's probably just as hard if not harder. Shouldn't it be easy to write a function (callable from Lisp) that emulates self-insert-command (and its special behavior w.r.t. undo), except that it takes a character as an argument? Davis -- This product is sold by volume, not by mass. If it appears too dense or too sparse, it is because mass-energy conversion has occurred during shipping.