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#59141: 28.1.90; Face :extend when all the line but trailing \n is invisible Date: Wed, 09 Nov 2022 19:12:32 +0200 Organization: LINKOV.NET Message-ID: <865yfovz6f.fsf@mail.linkov.net> References: <871qqcdfvr.fsf@localhost> <874jv8o9e4.fsf@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="6232"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (x86_64-pc-linux-gnu) Cc: 59141@debbugs.gnu.org, Ihor Radchenko To: =?UTF-8?Q?K=C3=A9vin?= Le Gouguec Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Wed Nov 09 18:28:32 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 1ososK-0001Wn-1M for geb-bug-gnu-emacs@m.gmane-mx.org; Wed, 09 Nov 2022 18:28:32 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1osort-0007yb-49; Wed, 09 Nov 2022 12:28: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 1osorq-0007wZ-Ry for bug-gnu-emacs@gnu.org; Wed, 09 Nov 2022 12:28:02 -0500 Original-Received: from debbugs.gnu.org ([209.51.188.43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1osorq-00067p-Jh for bug-gnu-emacs@gnu.org; Wed, 09 Nov 2022 12:28:02 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1osorq-00038I-G3 for bug-gnu-emacs@gnu.org; Wed, 09 Nov 2022 12:28:02 -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, 09 Nov 2022 17:28:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 59141 X-GNU-PR-Package: emacs Original-Received: via spool by 59141-submit@debbugs.gnu.org id=B59141.166801485511952 (code B ref 59141); Wed, 09 Nov 2022 17:28:02 +0000 Original-Received: (at 59141) by debbugs.gnu.org; 9 Nov 2022 17:27:35 +0000 Original-Received: from localhost ([127.0.0.1]:40791 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1osorP-00036i-AW for submit@debbugs.gnu.org; Wed, 09 Nov 2022 12:27:35 -0500 Original-Received: from relay9-d.mail.gandi.net ([217.70.183.199]:46751) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1osorN-00036S-Cz for 59141@debbugs.gnu.org; Wed, 09 Nov 2022 12:27:34 -0500 Original-Received: (Authenticated sender: juri@linkov.net) by mail.gandi.net (Postfix) with ESMTPSA id 9733AFF80C; Wed, 9 Nov 2022 17:27:23 +0000 (UTC) In-Reply-To: <874jv8o9e4.fsf@gmail.com> ("=?UTF-8?Q?K=C3=A9vin?= Le Gouguec"'s message of "Wed, 09 Nov 2022 08:49:07 +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:247453 Archived-At: >> I do not see anything wrong on the Org side. >> Maybe Emacs should not apply :extent t attribute to the newline when the >> text in fontified line is hidden? > > IIUC, this is bug#52587? And bug#53981. > The conclusion there, AFAIR, was "it's unfortunate, but that's the > design for now; let's rediscuss when we see some patches for outline.el > (or the specific modes that use extended backgrounds)". Here is an experimental patch for outline.el that demonstrates a possible way to fix this: diff --git a/lisp/outline.el b/lisp/outline.el index a646f71db8..73ae707821 100644 --- a/lisp/outline.el +++ b/lisp/outline.el @@ -930,7 +930,8 @@ outline-flag-region ;; We use `front-advance' here because the invisible text begins at the ;; very end of the heading, before the newline, so text inserted at FROM ;; belongs to the heading rather than to the entry. - (let ((o (make-overlay from to nil 'front-advance))) + (let ((o (make-overlay from (1+ to)))) + (overlay-put o 'display "\n") (overlay-put o 'evaporate t) (overlay-put o 'invisible 'outline) (overlay-put o 'isearch-open-invisible