GNU bug report logs -
#43315
28.0.50; Improvements to menu-bar Edit: add redo
Previous Next
Reported by: Caio Henrique <caiohcs0 <at> gmail.com>
Date: Thu, 10 Sep 2020 18:30:02 UTC
Severity: normal
Tags: fixed, patch
Found in version 28.0.50
Fixed in version 28.1
Done: Lars Ingebrigtsen <larsi <at> gnus.org>
Bug is archived. No further changes may be made.
To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 43315 in the body.
You can then email your comments to 43315 AT debbugs.gnu.org in the normal way.
Toggle the display of automated, internal messages from the tracker.
Report forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#43315
; Package
emacs
.
(Thu, 10 Sep 2020 18:30:02 GMT)
Full text and
rfc822 format available.
Acknowledgement sent
to
Caio Henrique <caiohcs0 <at> gmail.com>
:
New bug report received and forwarded. Copy sent to
bug-gnu-emacs <at> gnu.org
.
(Thu, 10 Sep 2020 18:30:02 GMT)
Full text and
rfc822 format available.
Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):
Hi,
After the recent discussions to improve discoverability of Emacs, I
analyzed the Emacs menu-bar and the menu bar of other text
editors. They all have a "Redo" option close to the "Undo".
Here are some examples:
1. nano
When you launch nano on the terminal, you can see the text on the bottom
that says "M-E Redo", right bellow "Undo".
2. libreoffice write
When you open the Edit menu, you will find that the first option is "Undo"
and the second is "Redo".
3. Notepad++
Same as libreoffice write.
4. Visual Studio Code
Same as libreoffice write.
Here is my proposal:
I'm not used to the default undo system since I use undo-tree, but it
seems that Emacs 28 has added a function called undo-redo to the
simple.el file, right? My proposal is to add it to the menu-bar, right
bellow "Undo":
_____
diff --git a/lisp/menu-bar.el b/lisp/menu-bar.el
index bc094c9050..30d86c7f17 100644
--- a/lisp/menu-bar.el
+++ b/lisp/menu-bar.el
@@ -536,6 +536,12 @@ menu-bar-edit-menu
(if (featurep 'ns)
(bindings--define-key menu [separator-undo] menu-bar-separator))
+ (bindings--define-key menu [undo-redo]
+ '(menu-item "Redo" undo-redo
+ :enable (and (not buffer-read-only)
+ (undo--last-change-was-undo-p buffer-undo-list))
+ :help "Undo last undo"))
+
(bindings--define-key menu [undo]
'(menu-item "Undo" undo
:enable (and (not buffer-read-only)
____
Cordially,
Caio Henrique
Added tag(s) patch.
Request was from
Lars Ingebrigtsen <larsi <at> gnus.org>
to
control <at> debbugs.gnu.org
.
(Thu, 10 Sep 2020 20:55:03 GMT)
Full text and
rfc822 format available.
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#43315
; Package
emacs
.
(Thu, 10 Sep 2020 21:00:02 GMT)
Full text and
rfc822 format available.
Message #10 received at 43315 <at> debbugs.gnu.org (full text, mbox):
Caio Henrique <caiohcs0 <at> gmail.com> writes:
> Here is my proposal:
> I'm not used to the default undo system since I use undo-tree, but it
> seems that Emacs 28 has added a function called undo-redo to the
> simple.el file, right? My proposal is to add it to the menu-bar, right
> bellow "Undo":
Makes sense to me, so I've applied your patch to Emacs 28.
It's small enough to do without a copyright assignment to the FSF, but
if it's likely/possible that you'll be submitting more patches in the
future, it might make sense to start the assignment process now. Would
you be willing to assign the copyright on Emacs patches to the FSF?
--
(domestic pets only, the antidote for overdose, milk.)
bloggy blog: http://lars.ingebrigtsen.no
Added tag(s) fixed.
Request was from
Lars Ingebrigtsen <larsi <at> gnus.org>
to
control <at> debbugs.gnu.org
.
(Thu, 10 Sep 2020 21:00:03 GMT)
Full text and
rfc822 format available.
bug marked as fixed in version 28.1, send any further explanations to
43315 <at> debbugs.gnu.org and Caio Henrique <caiohcs0 <at> gmail.com>
Request was from
Lars Ingebrigtsen <larsi <at> gnus.org>
to
control <at> debbugs.gnu.org
.
(Thu, 10 Sep 2020 21:00:03 GMT)
Full text and
rfc822 format available.
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#43315
; Package
emacs
.
(Thu, 10 Sep 2020 22:22:01 GMT)
Full text and
rfc822 format available.
Message #17 received at 43315 <at> debbugs.gnu.org (full text, mbox):
Lars Ingebrigtsen <larsi <at> gnus.org> writes:
> Would you be willing to assign the copyright on Emacs patches to the FSF?
Yes, can you send me the instructions/documents? Thanks!
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#43315
; Package
emacs
.
(Fri, 11 Sep 2020 04:19:02 GMT)
Full text and
rfc822 format available.
Message #20 received at 43315 <at> debbugs.gnu.org (full text, mbox):
[[[ To any NSA and FBI agents reading my email: please consider ]]]
[[[ whether defending the US Constitution against all enemies, ]]]
[[[ foreign or domestic, requires you to follow Snowden's example. ]]]
> + (bindings--define-key menu [undo-redo]
> + '(menu-item "Redo" undo-redo
> + :enable (and (not buffer-read-only)
> + (undo--last-change-was-undo-p buffer-undo-list))
> + :help "Undo last undo"))
> +
There is no harm putting it in the menu. But I doubt we can find a key for it.
--
Dr Richard Stallman
Chief GNUisance of the GNU Project (https://gnu.org)
Founder, Free Software Foundation (https://fsf.org)
Internet Hall-of-Famer (https://internethalloffame.org)
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#43315
; Package
emacs
.
(Fri, 11 Sep 2020 06:00:01 GMT)
Full text and
rfc822 format available.
Message #23 received at 43315 <at> debbugs.gnu.org (full text, mbox):
> Resent-From: Lars Ingebrigtsen <larsi <at> gnus.org>
> Original-Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
> Resent-CC: bug-gnu-emacs <at> gnu.org
> Resent-Sender: help-debbugs <at> gnu.org
> From: Lars Ingebrigtsen <larsi <at> gnus.org>
> Date: Thu, 10 Sep 2020 22:59:15 +0200
> Cc: 43315 <at> debbugs.gnu.org
>
> Caio Henrique <caiohcs0 <at> gmail.com> writes:
>
> > Here is my proposal:
> > I'm not used to the default undo system since I use undo-tree, but it
> > seems that Emacs 28 has added a function called undo-redo to the
> > simple.el file, right? My proposal is to add it to the menu-bar, right
> > bellow "Undo":
>
> Makes sense to me, so I've applied your patch to Emacs 28.
Thanks.
However, when we put a command on a menu item, we should make sure its
documentation is clear enough for newbies. In this case, the doc
string was so terse it was beyond obscure, and needed fixing to be
clear enough for a menu command. (I fixed it.)
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#43315
; Package
emacs
.
(Fri, 11 Sep 2020 06:37:02 GMT)
Full text and
rfc822 format available.
Message #26 received at 43315 <at> debbugs.gnu.org (full text, mbox):
> From: Caio Henrique <caiohcs0 <at> gmail.com>
> Date: Thu, 10 Sep 2020 19:21:07 -0300
> Cc: 43315 <at> debbugs.gnu.org, Caio Henrique <caiohcs0 <at> gmail.com>
>
> Lars Ingebrigtsen <larsi <at> gnus.org> writes:
>
> > Would you be willing to assign the copyright on Emacs patches to the FSF?
>
> Yes, can you send me the instructions/documents? Thanks!
Form and instructions sent off-list.
Thanks.
bug archived.
Request was from
Debbugs Internal Request <help-debbugs <at> gnu.org>
to
internal_control <at> debbugs.gnu.org
.
(Fri, 09 Oct 2020 11:24:06 GMT)
Full text and
rfc822 format available.
This bug report was last modified 4 years and 311 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.