From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: "Martin Edstrom" Newsgroups: gmane.emacs.bugs Subject: bug#72420: set-goal-column misbehaves with a line-prefix and visual-line-mode Date: Tue, 06 Aug 2024 16:24:16 +0200 (CEST) Message-ID: References: Mime-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="36170"; mail-complaints-to="usenet@ciao.gmane.io" Cc: Eli Zaretskii , 72420 <72420@debbugs.gnu.org> To: "Martin Edstrom" Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Tue Aug 06 17:24:08 2024 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1sbM2g-00098E-Op for geb-bug-gnu-emacs@m.gmane-mx.org; Tue, 06 Aug 2024 17:24:07 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1sbM2N-000414-Dj; Tue, 06 Aug 2024 11:23:47 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1sbM2F-000401-Kc for bug-gnu-emacs@gnu.org; Tue, 06 Aug 2024 11:23:40 -0400 Original-Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1sbM2F-0005Mg-BU for bug-gnu-emacs@gnu.org; Tue, 06 Aug 2024 11:23:39 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=debbugs.gnu.org; s=debbugs-gnu-org; h=Date:From:MIME-Version:To:In-Reply-To:References:Subject; bh=ssI6hp1atn2N7sEFd9B7AYnqLO+RBIDTTU1PE+4WGGA=; b=eaWWA8/0v6cLqMKpDx5gg7OrSvSVIj9edSz6I73MBB9s7b4NDibRNRDnbR6neo2yzNlOSW7I4Wc0ggDUjeB3vFf9rnU32OhdN0dPuNG28KMuSWf7eoH7PVhR40lsPhx6bsp7KLmjPwGBdUyUofOGTN9szaOhSaS4OmcELJrq2d7sJugsfDR59mifFwdzc25SQW/+kpuZLTbkwLkUjD+/eCgK9ZVLSDlRUFA5vPnQeP15ZFD+AHLM+Mb1NgbH+5lwiuDp4ntRqXcnoDXsc567Esm9CC3gm3t2g5Is//hh82p+9lOAT43cZ3bs4A47R7UsmA+W1vy2QdLeQHMkeEKuZQ==; Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1sbM2c-0000zd-6h for bug-gnu-emacs@gnu.org; Tue, 06 Aug 2024 11:24:02 -0400 X-Loop: help-debbugs@gnu.org In-Reply-To: Resent-From: "Martin Edstrom" Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Tue, 06 Aug 2024 15:24:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 72420 X-GNU-PR-Package: emacs Original-Received: via spool by 72420-submit@debbugs.gnu.org id=B72420.17229578133753 (code B ref 72420); Tue, 06 Aug 2024 15:24:02 +0000 Original-Received: (at 72420) by debbugs.gnu.org; 6 Aug 2024 15:23:33 +0000 Original-Received: from localhost ([127.0.0.1]:32889 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1sbM28-0000yQ-Ue for submit@debbugs.gnu.org; Tue, 06 Aug 2024 11:23:33 -0400 Original-Received: from mailtransmit05.runbox.com ([185.226.149.38]:54952) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1sbL9O-0007Pu-Gi for 72420@debbugs.gnu.org; Tue, 06 Aug 2024 10:27:01 -0400 Original-Received: from mailtransmit02.runbox ([10.9.9.162] helo=aibo.runbox.com) by mailtransmit05.runbox.com with esmtps (TLS1.2) tls TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 (Exim 4.93) (envelope-from ) id 1sbL6o-00DRTN-6h for 72420@debbugs.gnu.org; Tue, 06 Aug 2024 16:24:18 +0200 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=runbox.eu; s=selector1; h=Message-Id:Date:Subject:CC:To:From:MIME-Version: Content-Transfer-Encoding:Content-Type; bh=ssI6hp1atn2N7sEFd9B7AYnqLO+RBIDTTU1PE+4WGGA=; b=Uxke9pvoLbOZclBGYAcNg40Z8P pkuzQ0ltKhx+A++hoZ98AtBQ4BVi49jSykXlXo7h7ZAft+3yA8KEc7kcirLvO4XSsNOTJ2mivKFbY /NtxbIWcOOOuN26B5NEqfP7hbx0ADlvlDpiF8uUmzDt5P9nz+GXB2sx6DaFOm9jAnsXwAzbC++Kd4 fFN2AXQsH5n1wjR1siqdbkuWnxyborx5bUpRUGAlO5TBzJodabq44OQT1RMWBxU9O+g/lnYKWW6AU Y99TUNmk4DTWLCTrf+BCZ3z+/gj3h7MXOo36z8pgbmOOgmRcxPRFeKhscGVLAZajZidXIy4kQJOUh iUaI9UmQ==; Original-Received: from [10.9.9.127] (helo=rmmprod05.runbox) by mailtransmit02.runbox with esmtp (Exim 4.86_2) (envelope-from ) id 1sbL6n-0001B7-3F; Tue, 06 Aug 2024 16:24:17 +0200 Original-Received: from mail by rmmprod05.runbox with local (Exim 4.86_2) (envelope-from ) id 1sbL6n-0004Lx-1P; Tue, 06 Aug 2024 16:24:17 +0200 Content-Disposition: inline Original-Received: from [Authenticated alias (1196375)] by runbox.com with http (RMM6); Tue, 06 Aug 2024 14:24:16 GMT X-RMM-Aliasid: 1196375 X-Mailer: RMM6 X-Mailman-Approved-At: Tue, 06 Aug 2024 11:23:29 -0400 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.bugs:289832 Archived-At: I want to note that some email clients collapse strings of more than 1 spac= es to just 1 space, so if the expression (add-text-properties 72 73 '(line-= prefix " ")) seems to have a string with 1 space, try getting your clien= t to show you the unformatted source of the email. Martin Edstrom On Tue, 06 Aug 2024 16:10:09 +0200 (CEST), "Martin Edstrom" wrote: > Alright, I keep being mistaken about the reproducibility of my bug report= s, but I'm reasonably sure the following steps are reproducible. >=20 >=20 > Step 0: Start emacs -Q (emacs 29.4 if you have that version, Debian sid = package version 1:29.4+1-3) >=20 > Step 1: Erase the scratch buffer, and paste this text: >=20 > * h1 > ** h2 > - a.y......... > - x........... > *** h3 > **** h4 > - ....w....... > - z........... >=20 > Step 2: Use M-: to eval this expression: >=20 > (progn > (add-text-properties 12 13 '(line-prefix " ")) > (add-text-properties 27 28 '(line-prefix " ")) > (add-text-properties 57 58 '(line-prefix " ")) > (add-text-properties 72 73 '(line-prefix " ")) > (add-text-properties 12 13 '(display "=E2=80=A2")) > (add-text-properties 27 28 '(display "=E2=80=A2")) > (add-text-properties 57 58 '(display "=E2=80=A2")) > (add-text-properties 72 73 '(display "=E2=80=A2"))) >=20 > Step 3: Run M-x visual-line-mode. >=20 > Step 4: Move point to "z", inside the last line, and type C-x C-n (set-go= al-column). Say yes to the disabled-command prompt. >=20 > Now I would expect moving point upwards with C-p any number of times shou= ld still make point land on the text after the list bullet, but the goal co= lumn actually seems to be offset in some way influenced by the line prefix.= Even using C-n to come back to the line that has "z....." does not place p= oint on the same position as when you started out. >=20 >=20 > (Alternative reproduction steps: instead of step 2, use M-x org-mode RET = M-x org-indent-mode RET. That's how the bug was found.) >=20 > Martin Edstrom >=20 > On Sun, 04 Aug 2024 11:47:49 +0300, Eli Zaretskii wrote: >=20 > > > From: "Martin Edstr=C3=B6m" > > > Date: Fri, 02 Aug 2024 12:35:32 +0200 (CEST) > > >=20 > > > There remains a niggling issue related to bug 61580 ( https://lists.g= nu.org/archive/html/bug-gnu-emacs/2023-03/msg00094.html ) > > >=20 > > > Basically, reproduce that same setup. Now turn on M-x visual-line-mod= e and try to use M-x set-goal-column (C-x C-n). It does not stick to the g= oal column you choose. > >=20 > > Thanks, but please show a full recipe for reproducing this, starting > > from "emacs -Q". The original setup talks about an Org file(is that > > part necessary?) and some added text properties with absolute buffer > > positions, so I'd rather not guess how to repeat that. Please also > > describe in more detail what you mean by "does not stick to the goal > > column" -- which commands did you type that didn't honor the goal > > column?