From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: martin rudalics Newsgroups: gmane.emacs.devel Subject: Re: Proposal to improve the nomenclature of scrolling directions Date: Sat, 10 Nov 2012 12:05:40 +0100 Message-ID: <509E3504.1050500@gmx.at> References: <201211080338.qA83c7NY006393@winooski.ccs.neu.edu> <20635.16010.769769.433949@winooski.ccs.neu.edu> <509CD1EF.8070701@gmx.at> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-15; format=flowed Content-Transfer-Encoding: 7bit X-Trace: ger.gmane.org 1352545559 5620 80.91.229.3 (10 Nov 2012 11:05:59 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sat, 10 Nov 2012 11:05:59 +0000 (UTC) Cc: Eli Barzilay , emacs-devel@gnu.org To: Stefan Monnier Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Sat Nov 10 12:06:09 2012 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 1TX8t6-0002SI-Kk for ged-emacs-devel@m.gmane.org; Sat, 10 Nov 2012 12:06:08 +0100 Original-Received: from localhost ([::1]:37579 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TX8sw-0005Xn-Um for ged-emacs-devel@m.gmane.org; Sat, 10 Nov 2012 06:05:58 -0500 Original-Received: from eggs.gnu.org ([208.118.235.92]:51696) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TX8ss-0005XF-Ic for emacs-devel@gnu.org; Sat, 10 Nov 2012 06:05:57 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1TX8sp-0001E9-An for emacs-devel@gnu.org; Sat, 10 Nov 2012 06:05:54 -0500 Original-Received: from mailout-de.gmx.net ([213.165.64.23]:50513) by eggs.gnu.org with smtp (Exim 4.71) (envelope-from ) id 1TX8so-0001Dz-VK for emacs-devel@gnu.org; Sat, 10 Nov 2012 06:05:51 -0500 Original-Received: (qmail invoked by alias); 10 Nov 2012 11:05:48 -0000 Original-Received: from 62-47-54-255.adsl.highway.telekom.at (EHLO [62.47.54.255]) [62.47.54.255] by mail.gmx.net (mp017) with SMTP; 10 Nov 2012 12:05:48 +0100 X-Authenticated: #14592706 X-Provags-ID: V01U2FsdGVkX1+wBOksW3mwvNrNB2t/wv9pl3F5SjSMOhyTIulWNw XrUTRK8Q2fCdQX In-Reply-To: X-Y-GMX-Trusted: 0 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-Received-From: 213.165.64.23 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:154785 Archived-At: > I'm not sure we're talking about the same thing. I'm just talking about > the fact that the code he has right now does something similar to > advising/redefining some functions (which is the only way to do it for > an external package), Scrolling usually happens via commands. So external packages can always use pre- and post-command hooks (which I obviously not recommend). > and I'd rather just change those functions in the > source code instead. AFAICT scrolling is partially implemented in the scroll functions and partially in the display engine. For me, implementing a thing like `scroll-in-place' means to leave the scroll functions mainly untouched - we'd just record the original window-point and window-start positions there. Then we need a `scroll-point' overlay for the "line is too short" case (Kim Storm has implemented a similar feature in his rectangle code) and adjust it in a `post-display' hook - the one you've been asking for in the past decade. Also, that `post-display' hook would have to optionally handle the case where scrolling gets back to the original point and the user wants the window-start position to match the position it had before the scrolling sequence started. martin