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#56683: 29.0.50; long lines fix doesn't work correctly when lines are truncated Date: Tue, 26 Jul 2022 14:42:39 +0300 Message-ID: <835yjkdrrk.fsf@gnu.org> References: <87h73ab8bo.fsf@gmail.com> <83zgh2kzlo.fsf@gnu.org> <83y1wlllnc.fsf@gnu.org> <83mtd1li6o.fsf@gnu.org> <835yjpl5vm.fsf@gnu.org> <83y1wljmkn.fsf@gnu.org> <83r12djjvm.fsf@gnu.org> <8a3eaeef01b9a103450a@heytings.org> 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="14100"; mail-complaints-to="usenet@ciao.gmane.io" Cc: gerd.moellmann@gmail.com, andreyorst@gmail.com, 56683@debbugs.gnu.org To: Gregory Heytings Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Tue Jul 26 13:43:38 2022 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 1oGIyQ-0003WV-72 for geb-bug-gnu-emacs@m.gmane-mx.org; Tue, 26 Jul 2022 13:43:38 +0200 Original-Received: from localhost ([::1]:55618 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1oGIyP-0007Bm-6S for geb-bug-gnu-emacs@m.gmane-mx.org; Tue, 26 Jul 2022 07:43:37 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:51586) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oGIxq-0007AB-I5 for bug-gnu-emacs@gnu.org; Tue, 26 Jul 2022 07:43:05 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:34424) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1oGIxq-0000ZV-4n for bug-gnu-emacs@gnu.org; Tue, 26 Jul 2022 07:43:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1oGIxq-00085T-17 for bug-gnu-emacs@gnu.org; Tue, 26 Jul 2022 07:43:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Eli Zaretskii Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Tue, 26 Jul 2022 11:43:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 56683 X-GNU-PR-Package: emacs Original-Received: via spool by 56683-submit@debbugs.gnu.org id=B56683.165883576231057 (code B ref 56683); Tue, 26 Jul 2022 11:43:01 +0000 Original-Received: (at 56683) by debbugs.gnu.org; 26 Jul 2022 11:42:42 +0000 Original-Received: from localhost ([127.0.0.1]:52406 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oGIxW-00084q-EB for submit@debbugs.gnu.org; Tue, 26 Jul 2022 07:42:42 -0400 Original-Received: from eggs.gnu.org ([209.51.188.92]:38424) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oGIxU-00084b-5O for 56683@debbugs.gnu.org; Tue, 26 Jul 2022 07:42:41 -0400 Original-Received: from fencepost.gnu.org ([2001:470:142:3::e]:36670) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oGIxO-0000U9-S5; Tue, 26 Jul 2022 07:42:34 -0400 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=wGUe21z5/qifmIRjtBJkVwgte0035StKwPl49L8KSu4=; b=YeghwPM34qkNv6aXGUVC 7sXscAEEy+8/5PjBmGMP58oog+/aDAxGJtALP6V+RK2gdnXTQAafofBTOTvx8zReU8MbyUkUblwEM mSojRV7wU5rzr9ZpoPy1wr/Z+Ayxa6vdBUOErzAx0o2hPurAWXHfqqk1nYpo0AJ7j+ySS6tkCKFef qQzjapJJxYJyXh8q+RQ465A82JvGE6bXpCFJUauHOvOQBAXHWYENVfKwEEc3xImLps6naEN3qjkpH bd3XouildQHTD367t1q0IDknFYkDw2sk4NFPXR5BPcOE33KrOzGl6ZuXDiMFr7Ac/6f9mqoNdbyr0 jqmu0vkN+ieZWA==; Original-Received: from [87.69.77.57] (port=2669 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oGIxO-0007TL-58; Tue, 26 Jul 2022 07:42:34 -0400 In-Reply-To: <8a3eaeef01b9a103450a@heytings.org> (message from Gregory Heytings on Mon, 25 Jul 2022 22:22:22 +0000) 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" Xref: news.gmane.io gmane.emacs.bugs:237938 Archived-At: > Date: Mon, 25 Jul 2022 22:22:22 +0000 > From: Gregory Heytings > cc: Gerd Möllmann , > andreyorst@gmail.com, 56683@debbugs.gnu.org > > By the way, we should also decide what to do when the user enables > truncate-lines in a buffer with "really too long" lines. With > DISP_INFINITY == 10000000 (its current value), and with a character pixel > width of 20 (a not uncommon value nowadays with HiDPI screens), lines > longer than 500000 (single-width) characters will not be displayed > correctly. With a larger character pixel width, or with characters > occupying more than one column, that would be even less. > > Given: > > 1. that there has not been a single bug report about the fact that > truncate-line does not work correctly with "really too long" lines in the > last 20 years, This might be because no one seriously visited such files in Emacs until now. > 2. that the limit above, caused by DISP_INFINITY, is not much more than > 10000, the default value for long-line-threshold, and > > 3. the remaining slowdowns caused by truncate-lines, > > I'd be in favor of simply disabling truncate-lines when > long_line_optimizations_p is set. Maybe optionally. Or maybe displaying a message/warning suggesting that. I don't like disabling truncate-lines unconditionally in such buffers, I prefer leaving that to the user. And I think we should use INT_MAX instead of DISP_INFINITY, for the purpose of auto-hscroll. (There are several other uses of that macro, but I didn't yet look at all of them to see if it would make sense to increase DISP_INFINITY itself.)