From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.devel Subject: Re: UP and DOWN with multi-line minibuffer history Date: Mon, 14 Dec 2015 18:00:26 +0200 Message-ID: <838u4x3tr9.fsf@gnu.org> References: <83wpsj6978.fsf@gnu.org> <87y4czz63l.fsf@mail.linkov.net> <83lh8y5q3k.fsf@gnu.org> <8761019ybj.fsf@fencepost.gnu.org> Reply-To: Eli Zaretskii NNTP-Posting-Host: plane.gmane.org X-Trace: ger.gmane.org 1450108830 13064 80.91.229.3 (14 Dec 2015 16:00:30 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Mon, 14 Dec 2015 16:00:30 +0000 (UTC) Cc: emacs-devel@gnu.org, juri@linkov.net To: David Kastrup Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Mon Dec 14 17:00:25 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 1a8VXz-0005K2-VN for ged-emacs-devel@m.gmane.org; Mon, 14 Dec 2015 17:00:24 +0100 Original-Received: from localhost ([::1]:60690 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1a8VXz-00038P-Dz for ged-emacs-devel@m.gmane.org; Mon, 14 Dec 2015 11:00:23 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:34965) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1a8VXv-00038G-OZ for emacs-devel@gnu.org; Mon, 14 Dec 2015 11:00:20 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1a8VXr-0004QE-2K for emacs-devel@gnu.org; Mon, 14 Dec 2015 11:00:19 -0500 Original-Received: from fencepost.gnu.org ([2001:4830:134:3::e]:33937) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1a8VXq-0004QA-Vk; Mon, 14 Dec 2015 11:00:14 -0500 Original-Received: from 84.94.185.246.cable.012.net.il ([84.94.185.246]:4928 helo=HOME-C4E4A596F7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_128_CBC_SHA1:128) (Exim 4.82) (envelope-from ) id 1a8VXp-0006sV-S7; Mon, 14 Dec 2015 11:00:14 -0500 In-reply-to: <8761019ybj.fsf@fencepost.gnu.org> (message from David Kastrup on Mon, 14 Dec 2015 10:25:20 +0100) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 2001:4830:134:3::e 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:196244 Archived-At: > From: David Kastrup > Cc: Juri Linkov , emacs-devel@gnu.org > Date: Mon, 14 Dec 2015 10:25:20 +0100 > > Eli Zaretskii writes: > > > Sorry, I don't understand why supporting goal-column must have this > > side effect. In a normal buffer, we do support goal-column (in the > > visual-line sense), and still we don't jump to the firs screen line of > > a long logical line. > > Really? > > >From simple.el: > > (defun line-move (arg &optional noerror to-end try-vscroll) > "Move forward ARG lines. > If NOERROR, don't signal an error if we can't move ARG lines. > TO-END is unused. > TRY-VSCROLL controls whether to vscroll tall lines: if either > `auto-window-vscroll' or TRY-VSCROLL is nil, this function will > not vscroll." > [...] > (if (and line-move-visual > ;; Display-based column are incompatible with goal-column. > (not goal-column) > > A bit of git-blame work reveals that this was introduced by a certain > Eli Zaretskii in: > > commit 064f328a6ac90698c719b6eace60d6f4c90e3f08 > Author: Eli Zaretskii > Date: Fri Sep 16 20:15:16 2011 +0300 > > Fix bug #971 with next/previous-line when goal-column is set. > > lisp/simple.el (line-move): If goal-column is set, move by logical > lines, not by display lines. > (next-line, previous-line, goal-column, line-move-visual): Doc fix > to reflect the above change. I said "in the visual-line sense", and I meant it. You are looking at the wrong part of the code; you should instead look at how line-move-visual calls vertical-motion passing it the value of temporary-goal-column.