From unknown Sat Sep 13 11:13:18 2025 X-Loop: help-debbugs@gnu.org Subject: bug#79402: [PATCH] Fix focusing the first line of calc trail Resent-From: Wojciech Siewierski Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sun, 07 Sep 2025 14:23:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 79402 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: patch To: 79402@debbugs.gnu.org X-Debbugs-Original-To: bug-gnu-emacs@gnu.org Received: via spool by submit@debbugs.gnu.org id=B.17572549281203 (code B ref -1); Sun, 07 Sep 2025 14:23:01 +0000 Received: (at submit) by debbugs.gnu.org; 7 Sep 2025 14:22:08 +0000 Received: from localhost ([127.0.0.1]:44877 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1uvGHP-0000JL-Qz for submit@debbugs.gnu.org; Sun, 07 Sep 2025 10:22:08 -0400 Received: from lists.gnu.org ([2001:470:142::17]:44574) by debbugs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1uvGHC-0000Ib-CW for submit@debbugs.gnu.org; Sun, 07 Sep 2025 10:21:55 -0400 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 1uvGH4-0006PV-P6 for bug-gnu-emacs@gnu.org; Sun, 07 Sep 2025 10:21:47 -0400 Received: from mailtransmit04.runbox.com ([2a0c:5a00:149::25]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1uvGGt-0006Cg-Mj for bug-gnu-emacs@gnu.org; Sun, 07 Sep 2025 10:21:44 -0400 Received: from mailtransmit03.runbox ([10.9.9.163] helo=aibo.runbox.com) by mailtransmit04.runbox.com with esmtps (TLS1.2) tls TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 (Exim 4.93) (envelope-from ) id 1uvGGk-009ogw-2p for bug-gnu-emacs@gnu.org; Sun, 07 Sep 2025 16:21:26 +0200 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=siewierski.eu; s=selector2; h=Content-Type:MIME-Version:Message-ID:Date: Subject:To:From; bh=/xVeNMx+tr0YI1+fNOT+vzrAW+aCYHteJwdImCaeHv4=; b=Xm+VaTChJ fBg+LxX5ajk8FODpj0QwS6B9MQvHv1ZPExKU8QnZXcBfhyqLFpQ6HCjTYVFwVJuLPFS0SKmEa/4TT tLDUMLL0XQgoniDEpmK5vEhlBH73bZP/OKLh79xxzocnPGTRgzOnRZaeh43v9cLydg7YVUkSDKZTd FGP3LcJsE1aw1dFFGjwFPIcInsGcP+9p2iywBZtg2f1lQNo+mLdFu0ywQlHfpkEOeC9dj5QnCmokt 6j+Uv3HgiVQRRNHeMoQ/BjT+kofKwOvQ5YF+4WKjKH3Xzskcf9n5imUP9mMvfwwrJ5t2JxbbIHPJC m4U2Rk+0E5B46jCGGHifo/mqw==; Received: from [10.9.9.73] (helo=submission02.runbox) by mailtransmit03.runbox with esmtp (Exim 4.86_2) (envelope-from ) id 1uvGGj-0000xm-Kg for bug-gnu-emacs@gnu.org; Sun, 07 Sep 2025 16:21:25 +0200 Received: by submission02.runbox with esmtpsa [Authenticated ID (941579)] (TLS1.2:ECDHE_SECP256R1__RSA_PSS_RSAE_SHA256__AES_256_GCM:256) (Exim 4.93) id 1uvGGQ-00976n-Rg for bug-gnu-emacs@gnu.org; Sun, 07 Sep 2025 16:21:06 +0200 From: Wojciech Siewierski Date: Sun, 07 Sep 2025 16:21:03 +0200 Message-ID: <87y0qqbay8.fsf@bifrost.mail-host-address-is-not-set> MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" Received-SPF: pass client-ip=2a0c:5a00:149::25; envelope-from=wojciech@siewierski.eu; helo=mailtransmit04.runbox.com X-Spam_score_int: -27 X-Spam_score: -2.8 X-Spam_bar: -- X-Spam_report: (-2.8 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_LOW=-0.7, T_SPF_HELO_TEMPERROR=0.01, T_SPF_TEMPERROR=0.01 autolearn=ham autolearn_force=no X-Spam_action: no action X-Spam-Score: 0.9 (/) 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: -0.1 (/) --=-=-= Content-Type: text/plain Tags: patch As of GNU Emacs 30.2 calc-trail-first focuses the second calc-trail line, not the first one. It's caused by the no longer correct assumption that the first line contains a header (now handled with header-line-format since Emacs 28.1). This is closely related to bug#77816 (already merged). I'm attaching a patch. --=-=-= Content-Type: text/patch Content-Disposition: attachment; filename=0001-Fix-focusing-the-first-line-of-calc-trail.patch >From 7e1e0dcfe885d823e0d9e0b0796dfebc2105dfc5 Mon Sep 17 00:00:00 2001 From: Wojciech Siewierski Date: Sun, 7 Sep 2025 16:02:20 +0200 Subject: [PATCH] Fix focusing the first line of calc trail * lisp/calc/calc-trail.el (calc-trail-first): Fix an off by one error introduced when the in-buffer header line got replaced with header-line-format. Closely related to Bug#77816 --- lisp/calc/calc-trail.el | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lisp/calc/calc-trail.el b/lisp/calc/calc-trail.el index 433d3983b12..7bbf5e508b8 100644 --- a/lisp/calc/calc-trail.el +++ b/lisp/calc/calc-trail.el @@ -61,7 +61,7 @@ (interactive "p") (calc-with-trail-buffer (goto-char (point-min)) - (forward-line n) + (forward-line (1- n)) (calc-trail-here))) (defun calc-trail-last (n) -- 2.51.0 --=-=-=--