From debbugs-submit-bounces@debbugs.gnu.org Sat May 25 09:44:18 2019 Received: (at submit) by debbugs.gnu.org; 25 May 2019 13:44:18 +0000 Received: from localhost ([127.0.0.1]:48449 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hUWy9-0004jp-Rk for submit@debbugs.gnu.org; Sat, 25 May 2019 09:44:18 -0400 Received: from eggs.gnu.org ([209.51.188.92]:36489) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hUWy7-0004jT-Tf for submit@debbugs.gnu.org; Sat, 25 May 2019 09:44:16 -0400 Received: from lists.gnu.org ([209.51.188.17]:57134) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1hUWy2-0007UG-MC for submit@debbugs.gnu.org; Sat, 25 May 2019 09:44:10 -0400 Received: from eggs.gnu.org ([209.51.188.92]:50788) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hUWy1-0003iR-Jr for bug-gnu-emacs@gnu.org; Sat, 25 May 2019 09:44:10 -0400 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=0.8 required=5.0 tests=BAYES_50,URIBL_BLOCKED autolearn=disabled version=3.3.2 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1hUWmL-0005kR-3s for bug-gnu-emacs@gnu.org; Sat, 25 May 2019 09:32:06 -0400 Received: from metalevel.at ([78.46.218.83]:37076) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hUWmK-0005jV-Tv for bug-gnu-emacs@gnu.org; Sat, 25 May 2019 09:32:05 -0400 Received: from mt-Lenovo-ideapad-120S-11IAP (localhost.localdomain [127.0.0.1]) by metalevel.at (Postfix) with ESMTP id 371DBA03CB for ; Sat, 25 May 2019 15:31:58 +0200 (CEST) Received: by mt-Lenovo-ideapad-120S-11IAP (Postfix, from userid 1000) id E355914128F; Sat, 25 May 2019 15:31:57 +0200 (CEST) From: Markus Triska To: bug-gnu-emacs@gnu.org Subject: 26.1; move-beginning-of-line sometimes does not move to beginning of line Date: Sat, 25 May 2019 15:31:57 +0200 Message-ID: <875zpylkxe.fsf@metalevel.at> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 78.46.218.83 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: submit X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) Please download hello.png with: $ wget https://www.metalevel.at/ei/hello.png and then, starting Emacs with "emacs -Q", evaluate the following form: (progn (goto-char (point-min)) (save-excursion (insert "\n")) (goto-char (+ (point) (cadr (insert-image-file "hello.png")))) (move-beginning-of-line nil)) This yields: 592, and does not move point to the beginning of the line. However, the documentation of move-beginning-of-line includes: (If there=E2=80=99s an image in the line, this disregards newlines which are part of the text that the image rests on.) Hence, I expect this to move to position 1. For comparison, when I press C-a, it does move to position 1, as expected. Would you please consider adjusting the function so that it behaves as documented? Alternatively, could you please provide this feature in a different way? Thank you and all the best, Markus In GNU Emacs 26.1 (build 3, x86_64-pc-linux-gnu, X toolkit, Xaw scroll bars) of 2019-04-09 built on mt-laptop Windowing system distributor 'The X.Org Foundation', version 11.0.11906000 From debbugs-submit-bounces@debbugs.gnu.org Sat May 25 10:38:11 2019 Received: (at 35899) by debbugs.gnu.org; 25 May 2019 14:38:11 +0000 Received: from localhost ([127.0.0.1]:49343 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hUXoJ-0006Sx-3g for submit@debbugs.gnu.org; Sat, 25 May 2019 10:38:11 -0400 Received: from eggs.gnu.org ([209.51.188.92]:42363) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hUXoH-0006Sh-OI for 35899@debbugs.gnu.org; Sat, 25 May 2019 10:38:10 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]:60173) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hUXoC-0003PS-8I; Sat, 25 May 2019 10:38:04 -0400 Received: from [176.228.60.248] (port=3065 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1hUXoB-00025x-LB; Sat, 25 May 2019 10:38:04 -0400 Date: Sat, 25 May 2019 17:38:01 +0300 Message-Id: <838suu4n1y.fsf@gnu.org> From: Eli Zaretskii To: Markus Triska In-reply-to: <875zpylkxe.fsf@metalevel.at> (message from Markus Triska on Sat, 25 May 2019 15:31:57 +0200) Subject: Re: bug#35899: 26.1; move-beginning-of-line sometimes does not move to beginning of line References: <875zpylkxe.fsf@metalevel.at> MIME-version: 1.0 Content-type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 35899 Cc: 35899@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) > From: Markus Triska > Date: Sat, 25 May 2019 15:31:57 +0200 > > $ wget https://www.metalevel.at/ei/hello.png > > and then, starting Emacs with "emacs -Q", evaluate the following form: > > (progn > (goto-char (point-min)) > (save-excursion (insert "\n")) > (goto-char (+ (point) (cadr (insert-image-file "hello.png")))) > (move-beginning-of-line nil)) > > This yields: 592, and does not move point to the beginning of the line. > > However, the documentation of move-beginning-of-line includes: > > (If there’s an image in the line, this disregards newlines > which are part of the text that the image rests on.) > > Hence, I expect this to move to position 1. For comparison, when I press > C-a, it does move to position 1, as expected. "the text that the image rests on" refers to the text which is "covered" by the display property, not the newlines in the binary data that constitutes the image file's data. > Would you please consider adjusting the function so that it behaves as > documented? This function works on the logical/physical lines, not on visual lines. > Alternatively, could you please provide this feature in a different > way? I suggest to use beginning-of-visual-line instead. From debbugs-submit-bounces@debbugs.gnu.org Fri Jun 21 06:05:32 2019 Received: (at 35899) by debbugs.gnu.org; 21 Jun 2019 10:05:33 +0000 Received: from localhost ([127.0.0.1]:49685 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1heGQG-0007Xk-Hc for submit@debbugs.gnu.org; Fri, 21 Jun 2019 06:05:32 -0400 Received: from mail-io1-f43.google.com ([209.85.166.43]:42415) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1heGQF-0007XW-0A for 35899@debbugs.gnu.org; Fri, 21 Jun 2019 06:05:31 -0400 Received: by mail-io1-f43.google.com with SMTP id u19so1525196ior.9 for <35899@debbugs.gnu.org>; Fri, 21 Jun 2019 03:05:31 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:references:date:in-reply-to:message-id :user-agent:mime-version; bh=RZbL48F2w107lu6ejP2Ls84mfNb5m164A7o3s+iDoFM=; b=fmfmrhXbRvq0Wo7EI7ouW3gCANELm2DHMy2QatEAtIRvv8h4FRC3ef4WJrRLCp5GPc z9IC5FQSCnyNb0ZbA4T4zO7co+I3TEyr9j6eZ6cR60CUG8PuaxPsWyCFn9bToMZ8nAwW Rlv2l7N8F9h2FsxM+SbIG1+N2raLF9XfawsgpLEp+PE6UAIzNEtVS3T4tOg1D9d+rlsv 17AyILfQCocxz7yBGYnkf4GFkfPn+0KBY4GZzuizPHq8v6W+rYtSMJtQhoixvf2nH1TS VSR9hdFvbAABp7jZeF3M5Lo+0nAv/0jmEt9wNm5ciaw4yMQOlav8NkJcM/cfkIrRh6ij /44A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:references:date:in-reply-to :message-id:user-agent:mime-version; bh=RZbL48F2w107lu6ejP2Ls84mfNb5m164A7o3s+iDoFM=; b=E23AqFUbRiktrmKQuo8PBsXeI6/TH3peF9OEUXhHEtwEQFZPRZkQbMJnTchbZDvyIc n8mglYkyS1MkjpZdOJZmGj6MVzhqo2vvg4vibXmCsX4MEPQnsRuM9iIQFr2AOFljL678 +AVWlB1hxkWRr/JDs+cg3F4K3M50g5VxdDHnX5E8Qhvn8v3gnHQDhVkoMKNkzCuOkDH1 9X1HpAx4sxOdR1BbycohOj8u5LRTWtQSOcR9FM00ilA9/TYqoqUMJ83A04LFA4u7XwXg cg8NukCPzhDxo1AJ+tF2B1Eic6w4LzUHSjRHj9ujQGsmYFVdycuVKMy1mf07qmrJ0NDG /VKw== X-Gm-Message-State: APjAAAUGI202ZU20VEyKAkNAmw4HhKuJQtsY/W6KFRXTWfw1M0/+yr/M tkK83jE9RTL8qRASttkUxvyOZRSL X-Google-Smtp-Source: APXvYqz3Z46fz8cTdAp7b3Kqb2aoEcCFJRLBsJnxYTSCy7TN9RhMMDKxIG4b4SQ4vd+cQEBMtzVHeg== X-Received: by 2002:a5e:890f:: with SMTP id k15mr595613ioj.121.1561111525165; Fri, 21 Jun 2019 03:05:25 -0700 (PDT) Received: from minid (cbl-45-2-119-34.yyz.frontiernetworks.ca. [45.2.119.34]) by smtp.gmail.com with ESMTPSA id y17sm2892449ioa.40.2019.06.21.03.05.23 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Fri, 21 Jun 2019 03:05:24 -0700 (PDT) From: Noam Postavsky To: Eli Zaretskii Subject: Re: bug#35899: 26.1; move-beginning-of-line sometimes does not move to beginning of line References: <875zpylkxe.fsf@metalevel.at> <838suu4n1y.fsf@gnu.org> Date: Fri, 21 Jun 2019 06:05:22 -0400 In-Reply-To: <838suu4n1y.fsf@gnu.org> (Eli Zaretskii's message of "Sat, 25 May 2019 17:38:01 +0300") Message-ID: <871rznw8wt.fsf@gmail.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.2 (gnu/linux) MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 35899 Cc: 35899@debbugs.gnu.org, Markus Triska X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) --=-=-= Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Eli Zaretskii writes: >> However, the documentation of move-beginning-of-line includes: >>=20 >> (If there=E2=80=99s an image in the line, this disregards newlines >> which are part of the text that the image rests on.) >>=20 >> Hence, I expect this to move to position 1. For comparison, when I press >> C-a, it does move to position 1, as expected. > > "the text that the image rests on" refers to the text which is > "covered" by the display property, not the newlines in the binary data > that constitutes the image file's data. If I create an image which rests on some newlines like this: (let ((img (create-image "bug-35899-hello.png"))) (insert "abc") (insert-image img "foo\nbar\nbaz") (insert "def")) Then with point after "def", move-beginning-of-line stops "inside" the image. And I don't see anything in its code which would allow it to skip the image. Isn't this just a doc bug? --=-=-= Content-Type: text/x-diff Content-Disposition: inline; filename=0001-Clarify-docs-about-line-movement-Bug-35899.patch Content-Description: patch >From f64d539780c0aa8e1a3322afa518eb768f468e16 Mon Sep 17 00:00:00 2001 From: Noam Postavsky Date: Fri, 21 Jun 2019 05:52:14 -0400 Subject: [PATCH] Clarify docs about line movement (Bug#35899) * doc/lispref/positions.texi (Text Lines, Screen Lines): Add index entries. * lisp/simple.el (move-beginning-of-line): Remove incorrect mention of images, and reference beginning-of-visual-line. * src/editfns.c (Fline_beginning_position): Reference `vertical-motion'. --- doc/lispref/positions.texi | 3 +++ lisp/simple.el | 8 ++++---- src/editfns.c | 3 ++- 3 files changed, 9 insertions(+), 5 deletions(-) diff --git a/doc/lispref/positions.texi b/doc/lispref/positions.texi index 7707793467..128685800f 100644 --- a/doc/lispref/positions.texi +++ b/doc/lispref/positions.texi @@ -332,6 +332,8 @@ Buffer End Motion @node Text Lines @subsection Motion by Text Lines @cindex lines +@cindex logical lines, moving by +@cindex physical lines, moving by Text lines are portions of the buffer delimited by newline characters, which are regarded as part of the previous line. The first text line @@ -515,6 +517,7 @@ Text Lines @node Screen Lines @subsection Motion by Screen Lines @cindex screen lines, moving by +@cindex visual lines, moving by The line functions in the previous section count text lines, delimited only by newline characters. By contrast, these functions count screen diff --git a/lisp/simple.el b/lisp/simple.el index a0f2da7152..010a7ae563 100644 --- a/lisp/simple.el +++ b/lisp/simple.el @@ -6638,15 +6638,15 @@ (defun move-end-of-line (arg) (setq done t))))))) (defun move-beginning-of-line (arg) - "Move point to beginning of current line as displayed. -\(If there's an image in the line, this disregards newlines -which are part of the text that the image rests on.) + "Move point to visible beginning of current logical line. +This disregards any invisible newline characters. With argument ARG not nil or 1, move forward ARG - 1 lines first. If point reaches the beginning or end of buffer, it stops there. \(But if the buffer doesn't end in a newline, it stops at the beginning of the last line.) -To ignore intangibility, bind `inhibit-point-motion-hooks' to t." +To ignore intangibility, bind `inhibit-point-motion-hooks' to t. +For motion by visual lines, see `beginning-of-visual-line'." (interactive "^p") (or arg (setq arg 1)) diff --git a/src/editfns.c b/src/editfns.c index 9b76ae23ff..7e16fbd0ed 100644 --- a/src/editfns.c +++ b/src/editfns.c @@ -910,7 +910,8 @@ DEFUN ("line-beginning-position", This function ignores text display directionality; it returns the position of the first character in logical order, i.e. the smallest -character position on the line. +character position on the logical line. See `vertical-motion' for +movement by screen lines. This function constrains the returned position to the current field unless that position would be on a different line than the original, -- 2.11.0 --=-=-=-- From debbugs-submit-bounces@debbugs.gnu.org Fri Jun 21 08:31:28 2019 Received: (at 35899) by debbugs.gnu.org; 21 Jun 2019 12:31:28 +0000 Received: from localhost ([127.0.0.1]:49887 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1heIhU-0008EL-2L for submit@debbugs.gnu.org; Fri, 21 Jun 2019 08:31:28 -0400 Received: from eggs.gnu.org ([209.51.188.92]:58879) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1heIhS-000897-Gg for 35899@debbugs.gnu.org; Fri, 21 Jun 2019 08:31:27 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]:39062) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1heIhG-0003Qt-Vt; Fri, 21 Jun 2019 08:31:16 -0400 Received: from [176.228.60.248] (port=2287 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1heIhD-0008NS-Sk; Fri, 21 Jun 2019 08:31:14 -0400 Date: Fri, 21 Jun 2019 15:30:39 +0300 Message-Id: <838stvp1cg.fsf@gnu.org> From: Eli Zaretskii To: Noam Postavsky In-reply-to: <871rznw8wt.fsf@gmail.com> (message from Noam Postavsky on Fri, 21 Jun 2019 06:05:22 -0400) Subject: Re: bug#35899: 26.1; move-beginning-of-line sometimes does not move to beginning of line References: <875zpylkxe.fsf@metalevel.at> <838suu4n1y.fsf@gnu.org> <871rznw8wt.fsf@gmail.com> MIME-version: 1.0 Content-type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 35899 Cc: 35899@debbugs.gnu.org, triska@metalevel.at X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) > From: Noam Postavsky > Cc: Markus Triska , 35899@debbugs.gnu.org > Date: Fri, 21 Jun 2019 06:05:22 -0400 > > >> (If there’s an image in the line, this disregards newlines > >> which are part of the text that the image rests on.) > >> > >> Hence, I expect this to move to position 1. For comparison, when I press > >> C-a, it does move to position 1, as expected. > > > > "the text that the image rests on" refers to the text which is > > "covered" by the display property, not the newlines in the binary data > > that constitutes the image file's data. > > If I create an image which rests on some newlines like this: > > (let ((img (create-image "bug-35899-hello.png"))) > (insert "abc") > (insert-image img "foo\nbar\nbaz") > (insert "def")) > > Then with point after "def", move-beginning-of-line stops "inside" the > image. And I don't see anything in its code which would allow it to > skip the image. Isn't this just a doc bug? Sorry, I don't understand the scenario, or cannot reproduce it. For starters, there's no bug-35899-hello.png, but I guess any image will do, so I used splash.png. But then (move-beginning-of-line nil) moves to the beginning of "def", which is not inside the image. What did I miss? From debbugs-submit-bounces@debbugs.gnu.org Sat Jun 22 18:54:10 2019 Received: (at 35899) by debbugs.gnu.org; 22 Jun 2019 22:54:10 +0000 Received: from localhost ([127.0.0.1]:52669 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1heote-0001PU-0Q for submit@debbugs.gnu.org; Sat, 22 Jun 2019 18:54:10 -0400 Received: from mail-io1-f54.google.com ([209.85.166.54]:32803) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1heotb-0001PE-Lf for 35899@debbugs.gnu.org; Sat, 22 Jun 2019 18:54:08 -0400 Received: by mail-io1-f54.google.com with SMTP id u13so1186158iop.0 for <35899@debbugs.gnu.org>; Sat, 22 Jun 2019 15:54:07 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:references:date:in-reply-to:message-id :user-agent:mime-version; bh=4rMLl5WRcURdNLHZF5dAw/AWDft6WNEwmMK2to0tS0E=; b=dMWkRPq6bFRvUJuz8cCB49ULA1SOvASA/JB1H1KLCzkrDjTVwFrNWtGfR/C9T9FbLn 5dMZ+oqCmLLDDG9Q5mxAwsHo5CGXchVqRooH/SDGeghyND/B9pVFYVEUvmBj6EjPvsQS E2x3oG9OwkowiXgZhDbUIuzq9pDPnkWRnt0jVkoCHnEeix5NrTcw5s4bTvi0CEw9QdxY y2cAi/w7um1gtIw5SOb2tF+WkKzAmAJj9eSCR6s6G2eWWefwl42rjInYa05krZzd9Ful JD3zMVOUKSVuTNL+objgtXJ6zrn9/4P2bJXBdUQ3u5/HKLtVm75Xy8dUHcAr9hCuUZqL dbsg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:references:date:in-reply-to :message-id:user-agent:mime-version; bh=4rMLl5WRcURdNLHZF5dAw/AWDft6WNEwmMK2to0tS0E=; b=jBCrUECEeDDS+/Y0BVWoZhSOQjdiPFxB6LtkUJXzr4yG1IFplr6YEIqwGpcfNsOi9E Pad7YPKEbYZ4Kkc/nkL8QyI9WzwD2xjcWADSGpZviIPmokvc8W7aZKQXLtfLuIRmTnnr gQwKcBFbaYYQ1bF4rooyUi5kqkhPqQ3ESQvNT5o47EFyfTkWy+8gdDEDs1Nw2ek9PHi6 qtVBdkYj7uwsXAf2f5PtCTZYlS5jwx4OAqsffwrHokOmRQIKATGG7uYBIr8TgIKyr5x1 yIQAUiik+0oU3v+caRHF2jZ8PMhJKgOs183tzBN4hi1qAPR+/H1oWpJgh1OG1NRgEuWP /aaA== X-Gm-Message-State: APjAAAWgEoJXhvRdijaWyUJdhW6537nRx0ANe2LMDUYN6PTpmZzqsRye acHl4eACZRossqWCHzobYk8= X-Google-Smtp-Source: APXvYqy/INncYs0roNiwuVClRAO3G0O/g9HOl+CMJ0f4i1EZ1pvvYr1WFQ2xY6SlLCM9fxMi0R+m3g== X-Received: by 2002:a02:234b:: with SMTP id u72mr33623145jau.4.1561244041951; Sat, 22 Jun 2019 15:54:01 -0700 (PDT) Received: from minid (cbl-45-2-119-34.yyz.frontiernetworks.ca. [45.2.119.34]) by smtp.gmail.com with ESMTPSA id h19sm7866845iol.65.2019.06.22.15.54.01 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Sat, 22 Jun 2019 15:54:01 -0700 (PDT) From: Noam Postavsky To: Eli Zaretskii Subject: Re: bug#35899: 26.1; move-beginning-of-line sometimes does not move to beginning of line References: <875zpylkxe.fsf@metalevel.at> <838suu4n1y.fsf@gnu.org> <871rznw8wt.fsf@gmail.com> <838stvp1cg.fsf@gnu.org> Date: Sat, 22 Jun 2019 18:54:00 -0400 In-Reply-To: <838stvp1cg.fsf@gnu.org> (Eli Zaretskii's message of "Fri, 21 Jun 2019 15:30:39 +0300") Message-ID: <87y31ttenr.fsf@gmail.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.2 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 35899 Cc: 35899@debbugs.gnu.org, triska@metalevel.at X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) Eli Zaretskii writes: > For starters, there's no bug-35899-hello.png, but I guess any image will do, Sorry, I meant the "hello.png" attached to the OP (I tend to give bug-specific names locally), but indeed any image will do. > so I used splash.png. But then (move-beginning-of-line nil) moves to > the beginning of "def", which is not inside the image. What did I > miss? Hmm, something a bit funny here: M-x move-beginning-of-line and M-: (move-beginning-of-line nil) go to the beginning of "def", but C-a (which is bound to move-beginning-of-line) goes onto the image (same as C-4 C-b). I guess the switch to minibuffer affects things somehow? But neither of these behaviours seems to be "disregarding" the newlines that the "image rests on", i.e., it's different from what happens without the newlines: (let ((img (create-image "splash.png"))) (insert "abc") (insert-image img "foo bar baz") (insert "def")) From debbugs-submit-bounces@debbugs.gnu.org Sun Jun 23 11:54:45 2019 Received: (at 35899) by debbugs.gnu.org; 23 Jun 2019 15:54:45 +0000 Received: from localhost ([127.0.0.1]:54142 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hf4pJ-0001Ph-A8 for submit@debbugs.gnu.org; Sun, 23 Jun 2019 11:54:45 -0400 Received: from eggs.gnu.org ([209.51.188.92]:43575) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hf4pH-0001PQ-DI for 35899@debbugs.gnu.org; Sun, 23 Jun 2019 11:54:43 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]:49286) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hf4pB-0000Li-J5; Sun, 23 Jun 2019 11:54:37 -0400 Received: from [176.228.60.248] (port=4125 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1hf4pA-0002gj-Vt; Sun, 23 Jun 2019 11:54:37 -0400 Date: Sun, 23 Jun 2019 18:54:32 +0300 Message-Id: <83pnn4mh53.fsf@gnu.org> From: Eli Zaretskii To: Noam Postavsky In-reply-to: <87y31ttenr.fsf@gmail.com> (message from Noam Postavsky on Sat, 22 Jun 2019 18:54:00 -0400) Subject: Re: bug#35899: 26.1; move-beginning-of-line sometimes does not move to beginning of line References: <875zpylkxe.fsf@metalevel.at> <838suu4n1y.fsf@gnu.org> <871rznw8wt.fsf@gmail.com> <838stvp1cg.fsf@gnu.org> <87y31ttenr.fsf@gmail.com> X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 35899 Cc: 35899@debbugs.gnu.org, triska@metalevel.at X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) > From: Noam Postavsky > Cc: 35899@debbugs.gnu.org, triska@metalevel.at > Date: Sat, 22 Jun 2019 18:54:00 -0400 > > Eli Zaretskii writes: > > > For starters, there's no bug-35899-hello.png, but I guess any image will do, > > Sorry, I meant the "hello.png" attached to the OP (I tend to give > bug-specific names locally), but indeed any image will do. > > > so I used splash.png. But then (move-beginning-of-line nil) moves to > > the beginning of "def", which is not inside the image. What did I > > miss? > > Hmm, something a bit funny here: M-x move-beginning-of-line and M-: > (move-beginning-of-line nil) go to the beginning of "def", but C-a > (which is bound to move-beginning-of-line) goes onto the image (same as > C-4 C-b). It doesn't go into the image, it stops at the first character covered by the display property. > I guess the switch to minibuffer affects things somehow? Probably; I didn't try to dig into this. I don't really understand the significance of this example or what is it that we are requested to do. In this case "the beginning of line" is not well defined. > But neither of these behaviours seems to be "disregarding" the newlines > that the "image rests on", i.e., it's different from what happens > without the newlines: > > (let ((img (create-image "splash.png"))) > (insert "abc") > (insert-image img "foo bar baz") > (insert "def")) I don't object to the proposed change of documentation, although I don't see how it makes the issue significantly more clear. Point movement in the presence of images that conceal newlines is tricky to describe in any terms but those of how the display engine works. Thanks. From debbugs-submit-bounces@debbugs.gnu.org Sun Jun 23 12:32:04 2019 Received: (at 35899) by debbugs.gnu.org; 23 Jun 2019 16:32:04 +0000 Received: from localhost ([127.0.0.1]:54170 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hf5PQ-0002VS-FX for submit@debbugs.gnu.org; Sun, 23 Jun 2019 12:32:04 -0400 Received: from mail-io1-f48.google.com ([209.85.166.48]:32934) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hf5PO-0002Um-Um for 35899@debbugs.gnu.org; Sun, 23 Jun 2019 12:32:03 -0400 Received: by mail-io1-f48.google.com with SMTP id u13so436075iop.0 for <35899@debbugs.gnu.org>; Sun, 23 Jun 2019 09:32:02 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:references:date:in-reply-to:message-id :user-agent:mime-version; bh=pRvdHVHspEdsUtnIAPrxh0KJS+Dyj7cs40GeUyLLO4U=; b=J3CyNYLWI2aRYsAeUTig0yRJhB9INkJyFEQ4Yo6i9ZnTA5CW/KrzByCAHLIJSX1otv 0kTf9sIboBPY85W4oD43oqbsUAhKv/8hM1ulpj2bidt8/mzlm1ZvhQ2Oxwz+K/DgbwAy WqArfXEXn8DD8gK1VCHDpoNm9bTkQoSuv66QeP3ZjgaLCvPhtMqOaMy5KX7SdDjRPIyc 9PN5Y4wNppXCwMnKXCyPZmuVZ/crIRTb7X/fARGfT5+Nwkr4yak5UDj7aJAE/54aHF0/ JPo/uqVyRPe+Tj4yTqUZlABwQTc9hqoQQsd5sETVeYZyp2JfrV/uVttIMn7RTGlJg9t6 T5gg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:references:date:in-reply-to :message-id:user-agent:mime-version; bh=pRvdHVHspEdsUtnIAPrxh0KJS+Dyj7cs40GeUyLLO4U=; b=ip+SotAX9rLlioR7BETFXyeQzXRJi8+KnR769q14eHwy4CSDh3tqa5wAbUoqgJ5Cf9 wR/Q08/0qmwx1LzmtO9Ub12zkl7pyRISrv0gbHQG625BR2qXDG6WxEK4QFI8WCSBeBgK mJwwO9Lai6bzEXXLhN2l8bjlga+DcNyEr2gl+BEgUzlIy4IgdjveaXQjzegxwsOEZorr FJDJtW4iDybGLr3aD4lYhBFGeDyL8eRKvQuMcT63zRGx/IuMnkAS5nAmj9iK1EmiJZmw +xbKvNIAeUm4B6oeOzZutnO9RIAd8nbRFZhdu0uv4/Bf/dW4eL9eHlwsh2HQN8WXi4Wu nbww== X-Gm-Message-State: APjAAAVxPfpnhQQSvV+0mIJnQ7YQLRupUIsQWpILXqtSd+Vxq8sbjWWs GJwCvQGz4SFHWLpe04Q0hk1rcE5s X-Google-Smtp-Source: APXvYqw4jEBh4/8kizgZ6MaEA9dRtv4HYk7jTeb4k3X5hChAh1h1VZ1MCHL3suz4k1/bec/0OVKxfA== X-Received: by 2002:a5d:9d58:: with SMTP id k24mr23358877iok.116.1561307517221; Sun, 23 Jun 2019 09:31:57 -0700 (PDT) Received: from minid (cbl-45-2-119-34.yyz.frontiernetworks.ca. [45.2.119.34]) by smtp.gmail.com with ESMTPSA id c2sm7342732iok.53.2019.06.23.09.31.56 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Sun, 23 Jun 2019 09:31:56 -0700 (PDT) From: Noam Postavsky To: Eli Zaretskii Subject: Re: bug#35899: 26.1; move-beginning-of-line sometimes does not move to beginning of line References: <875zpylkxe.fsf@metalevel.at> <838suu4n1y.fsf@gnu.org> <871rznw8wt.fsf@gmail.com> <838stvp1cg.fsf@gnu.org> <87y31ttenr.fsf@gmail.com> <83pnn4mh53.fsf@gnu.org> Date: Sun, 23 Jun 2019 12:31:56 -0400 In-Reply-To: <83pnn4mh53.fsf@gnu.org> (Eli Zaretskii's message of "Sun, 23 Jun 2019 18:54:32 +0300") Message-ID: <87blyotg8z.fsf@gmail.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.2 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 35899 Cc: 35899@debbugs.gnu.org, triska@metalevel.at X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) Eli Zaretskii writes: >> Hmm, something a bit funny here: M-x move-beginning-of-line and M-: >> (move-beginning-of-line nil) go to the beginning of "def", but C-a >> (which is bound to move-beginning-of-line) goes onto the image (same as >> C-4 C-b). > > It doesn't go into the image, it stops at the first character covered > by the display property. Ah right, I misinterpreted the behaviour. >> But neither of these behaviours seems to be "disregarding" the newlines >> that the "image rests on", i.e., it's different from what happens >> without the newlines: >> >> (let ((img (create-image "splash.png"))) >> (insert "abc") >> (insert-image img "foo bar baz") >> (insert "def")) > > I don't object to the proposed change of documentation, although I > don't see how it makes the issue significantly more clear. Point > movement in the presence of images that conceal newlines is tricky to > describe in any terms but those of how the display engine works. Right, the proposed change just stops attempting to describe it at all (and adds references to visual line movement, which solves the OP's problem). From debbugs-submit-bounces@debbugs.gnu.org Fri Aug 21 09:09:27 2020 Received: (at 35899) by debbugs.gnu.org; 21 Aug 2020 13:09:27 +0000 Received: from localhost ([127.0.0.1]:45409 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1k96nP-0004qk-Ie for submit@debbugs.gnu.org; Fri, 21 Aug 2020 09:09:27 -0400 Received: from quimby.gnus.org ([95.216.78.240]:42480) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1k96nN-0004qT-Rx for 35899@debbugs.gnu.org; Fri, 21 Aug 2020 09:09:26 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnus.org; s=20200322; h=Content-Type:MIME-Version:Message-ID:In-Reply-To:Date: References:Subject:Cc:To:From:Sender:Reply-To:Content-Transfer-Encoding: Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender: Resent-To:Resent-Cc:Resent-Message-ID:List-Id:List-Help:List-Unsubscribe: List-Subscribe:List-Post:List-Owner:List-Archive; bh=6DZhb9QkhocOegRSIOESnhExOPTfWYr7Qz6st5AVycc=; b=sp8x1zDGP6pqDJh6MaHzUsoMDZ cCJwCTHTYYNaEvu4xQ+3wUHW56JyRRFTHBko/Tmc3gec9C08+vW992/089xaSQT4LdSLfsymTE7z/ /WKkzaw5Ok+9rSj5XTkBQQYu+mT/7DzgD2zk8oEz8tL27CApnoR/axqMfc2LC2nx9vn8=; Received: from cm-84.212.202.86.getinternet.no ([84.212.202.86] helo=xo) by quimby with esmtpsa (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1k96n7-00040p-OB; Fri, 21 Aug 2020 15:09:19 +0200 From: Lars Ingebrigtsen To: Noam Postavsky Subject: Re: bug#35899: 26.1; move-beginning-of-line sometimes does not move to beginning of line References: <875zpylkxe.fsf@metalevel.at> <838suu4n1y.fsf@gnu.org> <871rznw8wt.fsf@gmail.com> <838stvp1cg.fsf@gnu.org> <87y31ttenr.fsf@gmail.com> <83pnn4mh53.fsf@gnu.org> <87blyotg8z.fsf@gmail.com> X-Now-Playing: Aural Exciters's _Spooks in Space_: "My Boy Lollipop" Date: Fri, 21 Aug 2020 15:09:08 +0200 In-Reply-To: <87blyotg8z.fsf@gmail.com> (Noam Postavsky's message of "Sun, 23 Jun 2019 12:31:56 -0400") Message-ID: <87o8n4403v.fsf@gnus.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Report: Spam detection software, running on the system "quimby.gnus.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see @@CONTACT_ADDRESS@@ for details. Content preview: Noam Postavsky writes: >> I don't object to the proposed change of documentation, although I >> don't see how it makes the issue significantly more clear. Point >> movement in the presence of images that conceal newlines is [...] Content analysis details: (-2.9 points, 5.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -1.0 ALL_TRUSTED Passed through trusted hosts only via SMTP -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 35899 Cc: 35899@debbugs.gnu.org, Eli Zaretskii , triska@metalevel.at X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) Noam Postavsky writes: >> I don't object to the proposed change of documentation, although I >> don't see how it makes the issue significantly more clear. Point >> movement in the presence of images that conceal newlines is tricky to >> describe in any terms but those of how the display engine works. > > Right, the proposed change just stops attempting to describe it at all > (and adds references to visual line movement, which solves the OP's > problem). It seems that everybody agreed on the doc fixes, but they weren't applied at the time, so I did that now. -- (domestic pets only, the antidote for overdose, milk.) bloggy blog: http://lars.ingebrigtsen.no From debbugs-submit-bounces@debbugs.gnu.org Fri Aug 21 09:09:38 2020 Received: (at control) by debbugs.gnu.org; 21 Aug 2020 13:09:38 +0000 Received: from localhost ([127.0.0.1]:45412 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1k96nZ-0004r9-Ta for submit@debbugs.gnu.org; Fri, 21 Aug 2020 09:09:38 -0400 Received: from quimby.gnus.org ([95.216.78.240]:42496) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1k96nY-0004qv-7b for control@debbugs.gnu.org; Fri, 21 Aug 2020 09:09:36 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnus.org; s=20200322; h=Subject:From:To:Message-Id:Date:Sender:Reply-To:Cc: MIME-Version:Content-Type:Content-Transfer-Encoding:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:In-Reply-To:References:List-Id:List-Help:List-Unsubscribe: List-Subscribe:List-Post:List-Owner:List-Archive; bh=/NaK7usxeqZiLDhVRV4pW8N2VkZFv4Nj+ar3721/3Hc=; b=GmutIDqEWzqAye9dycDsITdfAD rPw7GM9JoWyYv/j/m0KYutB4kCrcBdktfBu1a9TgMO4W8gHpm1TtrtI2J2JNMQUukcCBLLS19cm7p iwOGN03QBRDEkU/YcjDUM5sK4xN+KUXP/mFnmR1I9Jcbbpcgvi48Xrf0tbOCQcoEQxrs=; Received: from cm-84.212.202.86.getinternet.no ([84.212.202.86] helo=xo) by quimby with esmtpsa (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1k96nQ-000413-GK for control@debbugs.gnu.org; Fri, 21 Aug 2020 15:09:30 +0200 Date: Fri, 21 Aug 2020 15:09:27 +0200 Message-Id: <87mu2o403c.fsf@gnus.org> To: control@debbugs.gnu.org From: Lars Ingebrigtsen Subject: control message for bug #35899 X-Spam-Report: Spam detection software, running on the system "quimby.gnus.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see @@CONTACT_ADDRESS@@ for details. Content preview: tags 35899 + patch tags 35899 fixed close 35899 28.1 quit Content analysis details: (-2.9 points, 5.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -1.0 ALL_TRUSTED Passed through trusted hosts only via SMTP -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: control X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) tags 35899 + patch tags 35899 fixed close 35899 28.1 quit From unknown Sat Jun 21 03:24:19 2025 Received: (at fakecontrol) by fakecontrolmessage; To: internal_control@debbugs.gnu.org From: Debbugs Internal Request Subject: Internal Control Message-Id: bug archived. Date: Sat, 19 Sep 2020 11:24:11 +0000 User-Agent: Fakemail v42.6.9 # This is a fake control message. # # The action: # bug archived. thanks # This fakemail brought to you by your local debbugs # administrator