From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.bugs Subject: bug#74924: 29.3; Buffer showing manpage jumps back to beginning Date: Sat, 28 Dec 2024 13:39:05 +0200 Message-ID: <86zfkgrq92.fsf@gnu.org> References: <87seqm302a.fsf@gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="1791"; mail-complaints-to="usenet@ciao.gmane.io" Cc: ture@turepalsson.se, stefankangas@gmail.com, 74924@debbugs.gnu.org To: Robert Pluim Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Sat Dec 28 12:40:10 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 1tRVAw-0000Ky-JI for geb-bug-gnu-emacs@m.gmane-mx.org; Sat, 28 Dec 2024 12:40:10 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1tRVAr-0004bF-6U; Sat, 28 Dec 2024 06:40:05 -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 1tRVAo-0004Yi-Lq for bug-gnu-emacs@gnu.org; Sat, 28 Dec 2024 06:40:02 -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 1tRVAo-0000T0-Du for bug-gnu-emacs@gnu.org; Sat, 28 Dec 2024 06:40:02 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=debbugs.gnu.org; s=debbugs-gnu-org; h=MIME-version:References:In-Reply-To:From:Date:To:Subject; bh=MikwydrNuYR5BMY/6zYyhrclZjScqRcE9MgmcbVxYKk=; b=qeA2rtivZg5HC/8FUT+8nx3cP3mY+vvJgJLbGXV1klYH0s29UUdajyh9KL1CJ7yaLiI9zdys1v9PpfQS4TlavP0FUqSH0FF086V9sudFfs0VCW4jK9mszyC1tUroJiaE2V3EeMLNAvuUh4Q8xBXv2LAxRjt4kds2oKvoxxjeCMysEN9g3PjzWuooURI50xoigV2/ZNqFOCP+77weunP7bKQBJQ5mrZQ/G0OswBm3HrHtsuF3DU7hUEC6fvZjYaNmu9z3OVh3XnrqVHfQoVozrcsCsDNF37DnbtL30r4Q0eftv4k2a0ILISwBtneRHGApeJNozocKnYRbsgZudT9Kmw==; Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1tRVAo-0008Sb-8K for bug-gnu-emacs@gnu.org; Sat, 28 Dec 2024 06:40:02 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Eli Zaretskii Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sat, 28 Dec 2024 11:40:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 74924 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: confirmed Original-Received: via spool by 74924-submit@debbugs.gnu.org id=B74924.173538595832452 (code B ref 74924); Sat, 28 Dec 2024 11:40:02 +0000 Original-Received: (at 74924) by debbugs.gnu.org; 28 Dec 2024 11:39:18 +0000 Original-Received: from localhost ([127.0.0.1]:49511 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tRVA6-0008RL-Av for submit@debbugs.gnu.org; Sat, 28 Dec 2024 06:39:18 -0500 Original-Received: from eggs.gnu.org ([209.51.188.92]:52460) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tRVA3-0008R6-Ak for 74924@debbugs.gnu.org; Sat, 28 Dec 2024 06:39:16 -0500 Original-Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1tRV9x-0000F1-2X; Sat, 28 Dec 2024 06:39:09 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=MIME-version:References:Subject:In-Reply-To:To:From: Date; bh=MikwydrNuYR5BMY/6zYyhrclZjScqRcE9MgmcbVxYKk=; b=qxsNXER17HEMumpI42Vc ydEDUUw9+dlzQTxSaHKOZ/gcI6p6UhHQhPAgQji0h0c7p+GB0XWmUUpt6V38ksPEJxTWwpzFdrvX+ VehS7PB2l1ATL3Yu0l9Cw6aDbmoy2m2wrvtGhsnYhEfG8Ie1fPrJF2PbYjLi3C0W+xVBLBaYrXTQC Fcg1ggQ4gnYR6mi63vIXHjtT+XWe7lV+KYfIs6p+oa1SDlrdygBqqcq7GGvLtnH9wKu+BlExoIPUP +AlmxRzZ/MUdkmm7DoI4nreHMsKPMQVVSII3H3DPbKgRLFCPYyl0fmLTTuSkrwojKwAQEbpqBEvCy Cg78LvgD0sBq3A==; In-Reply-To: <87seqm302a.fsf@gmail.com> (message from Robert Pluim on Tue, 17 Dec 2024 14:34:37 +0100) 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:297889 Archived-At: > Cc: Ture Pålsson , 74924@debbugs.gnu.org > From: Robert Pluim > Date: Tue, 17 Dec 2024 14:34:37 +0100 > > >>>>> On Tue, 17 Dec 2024 13:19:00 +0000, Stefan Kangas said: > > Stefan> found 74924 29.3 > Stefan> found 74924 31.0.50 > Stefan> tags 74924 + confirmed > Stefan> thanks > > Stefan> Ture Pålsson writes: > > >> 1. Run in a terminal window. Operating system seems not to matter; I can > >> reproduce on both macOS and Linux. > >> > >> 2. Set environment variable MANWIDTH to 80 . > >> > >> 3. Start Emacs ('emacs -nw -Q'). > >> > >> 4. Do M-x man, enter the name of some manpage, and type RET. > >> > >> 5. Switch to the manpage window (C-x o), and scroll down by typing 'C-v' > >> a few times. > >> > >> 6. Switch back to the *scratch* window (C-x o again). > >> > >> 7. After about a second, the manpage window jumps back to the beginning > >> of the buffer. > >> > >> My *guess* is that this is related to the changes in commit > >> 7e387c9e5265b98dbb3b986f8ab8ac2217052831, but that may well be a red > >> herring. > > Stefan> I can reproduce this on both 29.3 and master on GNU/Linux. > > > This code from man.el should be setq-localʼing Man-columns > unconditionally, I think (itʼs nil by default): > > (when (or window-system > (not (or (getenv "MANWIDTH") (getenv "COLUMNS")))) > ;; Since the page buffer is displayed beforehand, > ;; we can select its window and get the window/frame width. > (setq-local Man-columns (Man-columns)) > (setenv "COLUMNS" (number-to-string Man-columns))) If this fixes the problem, please install on master, and thanks.