all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: <jakanakaevangeli@chiru.no>
To: Lars Ingebrigtsen <larsi@gnus.org>, Philipp <p.stephani2@gmail.com>
Cc: 30204@debbugs.gnu.org
Subject: bug#30204: 27.0.50; Changing major mode resets non-default invisibility spec
Date: Mon, 06 Sep 2021 12:22:17 +0200	[thread overview]
Message-ID: <87zgsqknqe.fsf@miha-pc> (raw)
In-Reply-To: <87ilzfo13i.fsf@gnus.org>

Lars Ingebrigtsen <larsi@gnus.org> writes:

> Philipp <p.stephani2@gmail.com> writes:
>
>>> And I think this is correct behaviour -- if you've switched to
>>> fundamental-mode, then you don't want these remnants from markdown-mode
>>> to survive, I think?
>>
>> Yes, but they do survive, i.e. once markdown-mode has made some text
>> conditionally-visible (which it does for URLs etc.), I'd expect it to
>> become unconditionally-visible instead of unconditionally-invisible
>> when changing the major mode.
>
> That's true.  Hm...  Should major modes remove `invisible' text
> properties (where the value isn't t)?  No, that wouldn't be right,
> either.
>
> Uhm.  OK, if `buffer-invisibility-spec' isn't t,
> `kill-all-local-variables' could remove the `invisible' text property
> from all text that has a non-t value?
>
> That sounds like it would potentially be expensive, but a non-nil
> invisibility spec is quite unusual (and switching major modes, in
> general, is unusual (well, switching from anything but fundamental-mode
> is unusual)).
>
> I dunno.  Anybody have an opinion here?

markdown-mode should simply add `invisible' to
font-lock-extra-managed-props. Font-lock will then automatically remove
this property as well from the buffer in change-major-mode-hook.

>
> -- 
> (domestic pets only, the antidote for overdose, milk.)
>    bloggy blog: http://lars.ingebrigtsen.no





      parent reply	other threads:[~2021-09-06 10:22 UTC|newest]

Thread overview: 40+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-01-22  9:51 bug#30204: 27.0.50; Changing major mode resets non-default invisibility spec Philipp Stephani
2018-01-22 15:56 ` Eli Zaretskii
2018-01-22 20:42   ` Philipp Stephani
2018-01-22 20:47     ` Philipp Stephani
2021-08-13 12:50 ` Lars Ingebrigtsen
2021-09-04 18:35   ` Philipp
2021-09-05  8:53     ` Lars Ingebrigtsen
2021-09-05  9:34       ` Eli Zaretskii
2021-09-05  9:43         ` Lars Ingebrigtsen
2021-09-05  9:50           ` Eli Zaretskii
2021-09-05 10:12             ` Lars Ingebrigtsen
2021-09-05 10:32               ` Eli Zaretskii
2021-09-05 10:44                 ` Lars Ingebrigtsen
2021-10-06 10:55           ` Lars Ingebrigtsen
2021-10-07 22:21             ` Richard Stallman
2021-10-07 22:25               ` Lars Ingebrigtsen
2021-10-08 21:56                 ` Richard Stallman
2021-10-09 11:20                   ` Lars Ingebrigtsen
2021-10-10 16:50                     ` Juri Linkov
2021-10-10 18:07                       ` Eli Zaretskii
2021-10-11 21:12                         ` Richard Stallman
2021-10-10 23:26                     ` Richard Stallman
2021-10-11  3:01                       ` Phil Sainty
2021-10-11  8:19                       ` Lars Ingebrigtsen
2021-10-11  9:14                         ` Kévin Le Gouguec
2021-10-11 10:05                           ` Robert Pluim
2021-10-11 21:14                             ` Richard Stallman
2021-10-11 10:53                           ` Phil Sainty
2021-10-13 21:38                           ` Tomas Nordin
2021-10-11 21:15                         ` Richard Stallman
2021-10-12 12:04                           ` Lars Ingebrigtsen
2021-10-12 22:43                             ` Richard Stallman
2021-10-09 10:55                 ` Robert Pluim
2021-10-09 11:10                   ` Lars Ingebrigtsen
2021-10-09 11:15                     ` Robert Pluim
2021-10-09 11:28                       ` Lars Ingebrigtsen
2021-10-10 15:59                         ` Robert Pluim
2021-10-10 16:06                           ` Stefan Monnier
2021-10-10 16:15                             ` Robert Pluim
2021-09-06 10:22       ` jakanakaevangeli [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87zgsqknqe.fsf@miha-pc \
    --to=jakanakaevangeli@chiru.no \
    --cc=30204@debbugs.gnu.org \
    --cc=larsi@gnus.org \
    --cc=p.stephani2@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.