From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Juri Linkov Newsgroups: gmane.emacs.bugs Subject: bug#68881: 30.0.50; [PATCH] Field properties confuse 'outline-minor-mode' Date: Wed, 07 Feb 2024 19:37:11 +0200 Organization: LINKOV.NET Message-ID: <86a5ocgp74.fsf@mail.linkov.net> References: <83986cee-a32d-707f-6ee0-ec1ba2bd42c2@gmail.com> Mime-Version: 1.0 Content-Type: text/plain Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="18416"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/30.0.50 (x86_64-pc-linux-gnu) Cc: 68881@debbugs.gnu.org To: Jim Porter Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Wed Feb 07 18:48:19 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 1rXm1y-0004d5-Op for geb-bug-gnu-emacs@m.gmane-mx.org; Wed, 07 Feb 2024 18:48:18 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rXm1k-0001G2-4z; Wed, 07 Feb 2024 12:48: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 1rXm1d-0001Ea-Da for bug-gnu-emacs@gnu.org; Wed, 07 Feb 2024 12:47:58 -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 1rXm1V-0002Kb-Ru for bug-gnu-emacs@gnu.org; Wed, 07 Feb 2024 12:47:57 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1rXm1j-0004U6-Nk for bug-gnu-emacs@gnu.org; Wed, 07 Feb 2024 12:48:03 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Juri Linkov Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Wed, 07 Feb 2024 17:48:03 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 68881 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: patch Original-Received: via spool by 68881-submit@debbugs.gnu.org id=B68881.170732806517162 (code B ref 68881); Wed, 07 Feb 2024 17:48:03 +0000 Original-Received: (at 68881) by debbugs.gnu.org; 7 Feb 2024 17:47:45 +0000 Original-Received: from localhost ([127.0.0.1]:57861 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rXm1R-0004Sj-CZ for submit@debbugs.gnu.org; Wed, 07 Feb 2024 12:47:45 -0500 Original-Received: from relay1-d.mail.gandi.net ([217.70.183.193]:33905) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rXm1P-0004SI-Fs for 68881@debbugs.gnu.org; Wed, 07 Feb 2024 12:47:43 -0500 Original-Received: by mail.gandi.net (Postfix) with ESMTPSA id 680FF240004; Wed, 7 Feb 2024 17:47:23 +0000 (UTC) In-Reply-To: <83986cee-a32d-707f-6ee0-ec1ba2bd42c2@gmail.com> (Jim Porter's message of "Thu, 1 Feb 2024 15:51:57 -0800") X-GND-Sasl: juri@linkov.net 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:279569 Archived-At: > I'd like to add support for 'outline-minor-mode' in Eshell. However, > Eshell's use of field properties confuses outline.el. Attached is a WIP > patch + demo code for Eshell that should resolve this. > > The main issue was that outline.el uses 'line-beginning-position' and > friends, which respects field boundaries, but I think we want to avoid that > for 'outline-minor-mode'. Maybe we could use 'pos-bol' and friends instead, > but my understanding is that 'line-beginning-position' respects display > directionality (which we probably want), but 'pos-bol' doesn't. I'm not aware of any cases that would require restricting outlines to field boundaries. > You can try things out here by starting Eshell and activating > 'outline-minor-mode'. You can also see the problems by applying only the > Eshell part of the patch. Thanks. I tried and confirm that your outline.el patch fixes the issue. > Any thoughts? Is this the right way to go about this? (Note: I think the > Eshell side of things will take more work, which I'll address in a later > bug. However, this should be enough to show off the problems on the > outline.el side.) There is also one occurrence of 'line-end-position' in outline.el. Should it have 'inhibit-field-text-motion' as well?