GNU bug report logs - #47878
Mark outline commands as repeatable

Previous Next

Package: emacs;

Reported by: Philip Kaludercic <philipk <at> posteo.net>

Date: Sun, 18 Apr 2021 19:01:02 UTC

Severity: wishlist

Tags: fixed

Fixed in version 28.0.50

Done: Juri Linkov <juri <at> linkov.net>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: Philip Kaludercic <philipk <at> posteo.net>
To: 47878 <at> debbugs.gnu.org
Subject: bug#47878: Mark outline commands as repeatable
Date: Sun, 18 Apr 2021 19:00:17 +0000
[Message part 1 (text/plain, inline)]
This is a suggested extension for repeat-mode. outline-mode, especially
outline-minor-mode commands are somewhat inconvenient to access ("C-x @
C-<something>" requires me to change modifiers mid-input twice). When
repeat-mode is enabled, this would allow me to access all outline keys
in just one key-press.

One might want to discuss if outline-mode-prefix-map should be directly
marked as the repeat-map or if a subset should be used. My approach
requires less effort but might be more confusing.

-- 
	Philip K.

[0002-Mark-outline-mode-keys-as-repeatable.patch (text/x-diff, inline)]
From 060f1a9facd4e30bd0bca5b405dc6e544dca3cf9 Mon Sep 17 00:00:00 2001
From: Philip K <philipk <at> posteo.net>
Date: Sun, 18 Apr 2021 20:34:18 +0200
Subject: [PATCH 2/4] Mark outline-mode keys as repeatable

---
 lisp/outline.el | 6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/lisp/outline.el b/lisp/outline.el
index bce9c6b9e4..f5fbfb5b98 100644
--- a/lisp/outline.el
+++ b/lisp/outline.el
@@ -1274,6 +1274,12 @@ outline-cycle-buffer
       (setq outline--cycle-buffer-state 'show-all)
       (message "Show all")))))
 
+;;; mark all commands bound in `outline-mode-prefix-map' as
+;;; repeatable.
+(dolist (command (mapcar #'cdr (cdr outline-mode-prefix-map)))
+  (when (commandp command)
+    (put command 'repeat-map 'outline-mode-prefix-map)))
+
 (provide 'outline)
 (provide 'noutline)
 
-- 
2.30.2


This bug report was last modified 4 years and 16 days ago.

Previous Next


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