From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: JD Smith Newsgroups: gmane.emacs.bugs Subject: bug#67604: Motion problems with inline images Date: Wed, 6 Dec 2023 13:29:54 -0500 Message-ID: <13812AAC-3E6E-4621-B0DC-3D2CE87FA5D2@gmail.com> References: <83cyvn6wix.fsf@gnu.org> <190CBBD6-067F-41D8-B5EE-6E1643F01C02@gmail.com> <83ttoy5cqo.fsf@gnu.org> <4FF4BC61-297C-41CD-8094-5BFB7CF2594B@gmail.com> <83r0k259wv.fsf@gnu.org> <83plzm590d.fsf@gnu.org> <9F116A2F-AC1C-4E7D-8870-60561BFD537C@gmail.com> <83lea96d8n.fsf@gnu.org> <778F3EE6-3AC6-4D0E-86B0-CD22751F38B5@gmail.com> <83jzpt69my.fsf@gnu.org> <83h6kx5o2u.fsf@gnu.org> <8698018C-6994-4CD2-8810-F77A65D60212@gmail.com> <83ttow3t2h.fsf@gnu.org> <990D9D56-A1EF-4450-B5E2-C6F47FECC9E3@gmail.com> <83jzpr4ixu.fsf@gnu.org> Mime-Version: 1.0 (Mac OS X Mail 16.0 \(3774.200.91.1.1\)) Content-Type: multipart/alternative; boundary="Apple-Mail=_A8D138D2-462C-4C18-94C5-621A7206464C" Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="35795"; mail-complaints-to="usenet@ciao.gmane.io" Cc: 67604@debbugs.gnu.org To: Eli Zaretskii Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Wed Dec 06 19:31:25 2023 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 1rAwg9-00095m-HR for geb-bug-gnu-emacs@m.gmane-mx.org; Wed, 06 Dec 2023 19:31:25 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rAwfj-0007MS-8K; Wed, 06 Dec 2023 13:30:59 -0500 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 1rAwfa-0007Ki-Hd for bug-gnu-emacs@gnu.org; Wed, 06 Dec 2023 13:30:51 -0500 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 1rAwfa-0008Le-88 for bug-gnu-emacs@gnu.org; Wed, 06 Dec 2023 13:30:50 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1rAwfl-000699-P4 for bug-gnu-emacs@gnu.org; Wed, 06 Dec 2023 13:31:01 -0500 X-Loop: help-debbugs@gnu.org Resent-From: JD Smith Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Wed, 06 Dec 2023 18:31:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 67604 X-GNU-PR-Package: emacs Original-Received: via spool by 67604-submit@debbugs.gnu.org id=B67604.170188742723578 (code B ref 67604); Wed, 06 Dec 2023 18:31:01 +0000 Original-Received: (at 67604) by debbugs.gnu.org; 6 Dec 2023 18:30:27 +0000 Original-Received: from localhost ([127.0.0.1]:40429 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rAwfC-00068D-Hn for submit@debbugs.gnu.org; Wed, 06 Dec 2023 13:30:27 -0500 Original-Received: from mail-yb1-xb34.google.com ([2607:f8b0:4864:20::b34]:46095) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rAwfA-00067w-Tr for 67604@debbugs.gnu.org; Wed, 06 Dec 2023 13:30:26 -0500 Original-Received: by mail-yb1-xb34.google.com with SMTP id 3f1490d57ef6-d9caf5cc948so118680276.0 for <67604@debbugs.gnu.org>; Wed, 06 Dec 2023 10:30:12 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1701887407; x=1702492207; darn=debbugs.gnu.org; h=references:to:cc:in-reply-to:date:subject:mime-version:message-id :from:from:to:cc:subject:date:message-id:reply-to; bh=VTWsx98uPYTEGfs49YtUxDqARnihqg6lPQXk2SuxLHs=; b=B5LwHlzkysWhCa2lz9FdAlrR6PmCzpK+/vz46vbq2kw1Zuqn/kkJt3y+IF6iugvQnR DMlw4peNV5+ezGI2w9usvUdmnwsw8cMRtMGsNrC2hr2Ck4sp6CnYpAlS9MgKWCQcSVXh ptGDh37leaUnAEKF4z+pm3AQEqtu7zONobMlhephrKSvdm63JyBUQyyiQOmlKX9n5haq Fkt8qxwKgZR1/3+oKSbVNiwsnCvJD0W5woBoD0jWPgRRpRmVFJcYLPG3WUI75ZRD0rOa r+cXTDv0S9q+JNbxNh9c+qmtzLdfn25O9RpFVVkke0V0RbAAhCJGhw71bZkFFk9eERsN ZUEA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1701887407; x=1702492207; h=references:to:cc:in-reply-to:date:subject:mime-version:message-id :from:x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=VTWsx98uPYTEGfs49YtUxDqARnihqg6lPQXk2SuxLHs=; b=Ygke7PP82ueYsqAG7yUAwJLDS82lAXuZjabap274SQcPV4YISl1xybZCoeANyEezBB p99MZinhrpQK/YVRM8BzQBikrrH72VDqGG8rVtl/C6MQZ4nwWTl1GelPm4Oh8GcGspdw WKzx5BUmTqGzmyafPEXo42r15G7x47m+tVDO723/NrKKOPYgev11Vt+jfKWgr9Y/Vfm3 cjQZ4FhLrUINd8xKq23qAFdolpisCBt3xXl4DXqdx4as/T5OX7ELvPXrPeziv6O9qQWc Wkvep/uEkSwcmoILK1hDxkY0g/9QhL+ebqK60T4UaRHg16lUP3Sl61etyYKenDX3BM1x KgWQ== X-Gm-Message-State: AOJu0Yy8RSyO/hLx6AyRiwF1ALmllZE4vpi9teYBNn29rRfKhBPnSyMg nHLrJO6EhrGGNWwqyAQUzNBE8BppEAc= X-Google-Smtp-Source: AGHT+IGdHvPqkywnhMDJmuJzQP+cbjmBqOOv9zPwwr6OKPC35MNr2FnTAXI+HB9RmIsXpTqh7JcXjw== X-Received: by 2002:a25:9206:0:b0:db7:dacf:3fae with SMTP id b6-20020a259206000000b00db7dacf3faemr1244070ybo.91.1701887407204; Wed, 06 Dec 2023 10:30:07 -0800 (PST) Original-Received: from smtpclient.apple ([131.183.131.33]) by smtp.gmail.com with ESMTPSA id d7-20020a258247000000b00d9ab86bdaffsm3923491ybn.12.2023.12.06.10.30.06 (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128); Wed, 06 Dec 2023 10:30:06 -0800 (PST) In-Reply-To: <83jzpr4ixu.fsf@gnu.org> X-Mailer: Apple Mail (2.3774.200.91.1.1) 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:275616 Archived-At: --Apple-Mail=_A8D138D2-462C-4C18-94C5-621A7206464C Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=utf-8 > On Dec 6, 2023, at 7:25=E2=80=AFAM, Eli Zaretskii = wrote: >=20 >> From: JD Smith >> Date: Tue, 5 Dec 2023 23:33:42 -0500 >> Cc: 67604@debbugs.gnu.org >>=20 >> Not really, no. But reproducing the problem is just a step towards >> debugging it, so the alternative is for you to step through next-line >> and its subroutines >>=20 >> I stepped through next-line and subroutines via edebug and landed via = line-move-visual on: >>=20 >> (vertical-motion (cons (or goal-column >> (if (consp temporary-goal-column) >> (car temporary-goal-column) >> temporary-goal-column)) >> arg)) >>=20 >> So vertical-motion is where all fingers point. >=20 > Did you verify that goal-column and temporary-goal-column have correct > values in the case where the problem happens? Yes. Sometimes the temporary-goal-column is 0 (if I C-a on a text line) = or sometimes a fractional number like 66.5 or similar if I start my = downward movement by first C-a=E2=80=99ing on the green image line. In = both cases the short screen line #3 line is skipped. >> It isn't like I'm the only >> one who should be able to read the code and understand where it = fails. >>=20 >> I agree with that, but unfortunately am not setup for it here and = have next to no familiarity with Emacs=E2=80=99 >> C code. I=E2=80=99m sorry I can=E2=80=99t be of more help. But = similar to how you were unable to work with dvisvgm >> and other packages, I don=E2=80=99t have access to gdb, as it is not = supported on my architecture. >=20 > If someone can reproduce and debug the problem on a system other than > macOS, that would be some progress. (If the problem is specific to > macOS, it is much less interesting, at least to me, since the display > code on macOS behaves differently in significant ways, and because > macOS is in general an idiosyncratic platform.) I have made progress. I built master on a remote Linux server and ran = it via X forwarding. With an 8x17 font, the bug is found at offset 2 =3D = 148 pixel width of the red SVG, for the specific frame-width =3D 74. I = verified that (vertical-motion 1) causes the same line-skip error, when = starting from the green image. =20 This makes me think that your difficulty reproducing the bug on your = system may result from a miscommunication. To be sure, I=E2=80=99ve = recorded a session of me (re-)discovering the bug at this comment = . Hopefully that=E2=80=99s = useful. =20 If not, I did the build on my Linux server with debug options, and can = run over gdb. If you can give me a simple recipe for where I should = break and what I should look at, I=E2=80=99m happy to try. But I = suspect it will be 25x more efficient for you to have a look if you can = reproduce. Re MacOS, I=E2=80=99m surprised you wouldn=E2=80=99t say that Windows is = similarly an idiosyncratic system for display and other purposes.= --Apple-Mail=_A8D138D2-462C-4C18-94C5-621A7206464C Content-Transfer-Encoding: quoted-printable Content-Type: text/html; charset=utf-8

On Dec 6, 2023, at 7:25=E2=80=AFAM, Eli Zaretskii = <eliz@gnu.org> wrote:

From: JD Smith = <jdtsmith@gmail.com>
Date: Tue, 5 Dec 2023 23:33:42 = -0500
Cc: 67604@debbugs.gnu.org

Not really, no.  But = reproducing the problem is just a step towards
debugging it, so the = alternative is for you to step through next-line
and its = subroutines

I stepped through next-line and subroutines via = edebug and landed via line-move-visual on:

(vertical-motion =  (cons (or goal-column
    (if (consp = temporary-goal-column)
(car = temporary-goal-column)
      temporary-go= al-column))
arg))

So vertical-motion is where all fingers = point.

Did you = verify that goal-column and temporary-goal-column have correct
values in the case where the problem = happens?

Yes.  Sometimes the = temporary-goal-column is 0 (if I C-a on a text line) or sometimes a = fractional number like 66.5 or similar if I start my downward movement = by first C-a=E2=80=99ing on the green image line.  In both cases = the short screen line #3 line is skipped.

It isn't like I'm the only
one who should be = able to read the code and understand where it fails.

I agree with = that, but unfortunately am not setup for it here and have next to no = familiarity with Emacs=E2=80=99
C code.  I=E2=80=99m sorry I = can=E2=80=99t be of more help.  But similar to how you were unable = to work with dvisvgm
and other packages, I don=E2=80=99t have access = to gdb, as it is not supported on my architecture.

If someone can reproduce and debug the = problem on a system other than
macOS, = that would be some progress.  (If the problem is specific = to
macOS, it is much less = interesting, at least to me, since the display
code on macOS behaves differently in = significant ways, and because
macOS = is in general an idiosyncratic = platform.)

I have made progress. =  I built master on a remote Linux server and ran it via X = forwarding.  With an 8x17 font, the bug is found at offset 2 =3D = 148 pixel width of the red SVG, for the specific frame-width =3D 74. =   I verified that (vertical-motion 1) causes the same line-skip = error, when starting from the green image. =  

This makes me think that your difficulty = reproducing the bug on your system may result from a miscommunication. =  To be sure, I=E2=80=99ve recorded a session of me (re-)discovering = the bug at this comment. =  Hopefully that=E2=80=99s useful. =  

If not, I did the build on my Linux = server with debug options, and can run over gdb. If you can give me a = simple recipe for where I should break and what I should look at, I=E2=80=99= m happy to try.  But I suspect it will be 25x more efficient for = you to have a look if you can reproduce.

Re = MacOS, I=E2=80=99m surprised you wouldn=E2=80=99t say that Windows is = similarly an idiosyncratic system for display and other = purposes.
= --Apple-Mail=_A8D138D2-462C-4C18-94C5-621A7206464C--