GNU bug report logs - #71405
30.0.50; separator line in string-edit's *edit string* buffer can be deleted

Previous Next

Package: emacs;

Reported by: Nicholas Vollmer <nv <at> parenthetic.dev>

Date: Fri, 7 Jun 2024 03:51:02 UTC

Severity: normal

Found in version 30.0.50

Done: Eli Zaretskii <eliz <at> gnu.org>

Bug is archived. No further changes may be made.

Full log


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

From: Eli Zaretskii <eliz <at> gnu.org>
To: Nicholas Vollmer <nv <at> parenthetic.dev>
Cc: 71405 <at> debbugs.gnu.org
Subject: Re: bug#71405: 30.0.50;
 separator line in string-edit's *edit string* buffer can be deleted
Date: Sat, 08 Jun 2024 16:02:54 +0300
> From: Nicholas Vollmer <nv <at> parenthetic.dev>
> Date: Thu, 06 Jun 2024 11:55:01 -0400
> 
> 
> 1. emacs -q
> 2. eval (string-edit "test" "" #'ignore :abort-callback #'ignore)
> 3. In the "*edit string*" buffer delete-backward-char
> 
> Observe the separator line has been deleted.
> Attempting to insert a character will user-error "Text is 
> read-only".

Does the patch below give good results?

diff --git a/lisp/textmodes/string-edit.el b/lisp/textmodes/string-edit.el
index 03be426..2a96289 100644
--- a/lisp/textmodes/string-edit.el
+++ b/lisp/textmodes/string-edit.el
@@ -58,7 +58,8 @@ string-edit
                              (list 'intangible t
                                    'face 'string-edit-prompt
                                    'read-only t))
-        (insert (propertize (make-separator-line) 'rear-nonsticky t))
+        (insert (propertize (make-separator-line)
+                            'read-only t 'rear-nonsticky t))
         (add-text-properties (point-min) (point)
                              (list 'string-edit--prompt t))))
     (let ((start (point)))




This bug report was last modified 342 days ago.

Previous Next


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