GNU bug report logs - #75530
[PATCH 0/3] Consistently remap read-only-mode for special edit modes

Previous Next

Package: emacs;

Reported by: Liam Hupfer <liam <at> hpfr.net>

Date: Mon, 13 Jan 2025 00:58:02 UTC

Severity: normal

Tags: patch

Full log


Message #68 received at 75530 <at> debbugs.gnu.org (full text, mbox):

From: Liam Hupfer <liam <at> hpfr.net>
To: Howard Melman <hmelman <at> gmail.com>, 75530 <at> debbugs.gnu.org
Subject: Re: bug#75530: [PATCH v2 2/3] Remap read-only-mode for Occur modes
 (bug#75530)
Date: Mon, 03 Feb 2025 22:52:12 -0600
[Message part 1 (text/plain, inline)]
Hi Howard,

Don’t forget to reply all! Not everyone subscribes to bug-gnu-emacs. I
just happened to check this thread on <https://yhetil.org>. Fortunately
[piem-inject-thread-into-maildir] makes it easy to correct this. Might
have to make that a habit on my end.

Howard Melman <hmelman <at> gmail.com> writes:

> I am all for consistency in these three mode, see Emacs bug#16214. But
> in that discussion people brought up that unlike for dired, for occur
> and grep, people sometimes use those commands to (1) search for and
> collect text, and then edit into something (say a list or paragraph)
> rather than wanting to (2) edit changes into the original sources
> (which they also want to do some other times). So the proposal was to
> leave C-x C-q to change read-only to cover the first case and to use
> “e” to enter the “writable” modes in all three cases and for the
> second case. C-x C-q in dired was fine to leave to enter wdired since
> (1) it already does that and (2) people don’t edit the output there
> much.

Looks like you’re referring to [Juri’s reply]:

> The difference is because it’s more useful to type `C-x C-q’ to change
> read-onlyness of an occur buffer and edit it textually than to do the
> same in a dired buffer where random edits (other than renaming file
> names) make less sense.

This is a little confusing to me. ‘read-only-mode’ on its own will make
the buffer editable, but won’t it leave Occur or Grep’s special bindings
in place? So you can’t even insert text! Seems to me that
‘fundamental-mode’ followed by ‘read-only-mode’ (which would then be
available on ‘C-x C-q’) would be needed? Or ‘switch-to-buffer’ plus
‘insert-buffer’? Not to mention Occur uses text properties to make the
line numbers read-only even when the buffer is writable. Maybe that
wasn’t the case in 2013.

I don’t mean to prescribe people their [workflows], of course. Maybe I’m
missing something?

Thanks!


[piem-inject-thread-into-maildir] <https://docs.kyleam.com/piem.html>

[Juri’s reply] <https://yhetil.org/emacs/87sitl51un.fsf <at> mail.jurta.org/>

[workflows] <https://xkcd.com/1172/>

This bug report was last modified 135 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.