[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] 149/287: Backport `make-composed-keymap'.
From: |
Matthew Fidler |
Subject: |
[elpa] 149/287: Backport `make-composed-keymap'. |
Date: |
Wed, 02 Jul 2014 14:45:29 +0000 |
mlf176f2 pushed a commit to branch externals/ergoemacs-mode
in repository elpa.
commit 764b0505f0ff28d63fd985cb111381bfc5b1808e
Author: Matthew L. Fidler <address@hidden>
Date: Wed Jun 18 13:46:26 2014 -0500
Backport `make-composed-keymap'.
---
ergoemacs-mode.el | 16 ++++++++++++++++
1 files changed, 16 insertions(+), 0 deletions(-)
diff --git a/ergoemacs-mode.el b/ergoemacs-mode.el
index cab9b0e..40b8cfa 100644
--- a/ergoemacs-mode.el
+++ b/ergoemacs-mode.el
@@ -258,6 +258,22 @@ Valid values are:
(defvar ergoemacs-unbind-keys nil)
(defvar ergoemacs-read-input-keys nil)
+(unless (fboundp 'make-composed-keymap)
+ ;; Backport `make-composed-keymap'
+ (defun make-composed-keymap (maps &optional parent)
+ "Construct a new keymap composed of MAPS and inheriting from PARENT.
+When looking up a key in the returned map, the key is looked in each
+keymap of MAPS in turn until a binding is found.
+If no binding is found in MAPS, the lookup continues in PARENT, if non-nil.
+As always with keymap inheritance, a nil binding in MAPS overrides
+any corresponding binding in PARENT, but it does not override corresponding
+bindings in other keymaps of MAPS.
+MAPS can be a list of keymaps or a single keymap.
+PARENT if non-nil should be a keymap."
+ `(keymap
+ ,@(if (keymapp maps) (list maps) maps)
+ ,@parent)))
+
(unless (featurep 'ergoemacs-theme-engine)
(load "ergoemacs-theme-engine"))
- [elpa] 83/287: Allow ergoemacs-rm-key to remove a list, (continued)
- [elpa] 83/287: Allow ergoemacs-rm-key to remove a list, Matthew Fidler, 2014/07/02
- [elpa] 84/287: Break-out sending unread-command events, Matthew Fidler, 2014/07/02
- [elpa] 85/287: Keep track of shortcut key prefixes, Matthew Fidler, 2014/07/02
- [elpa] 81/287: Added version menu back, Matthew Fidler, 2014/07/02
- [elpa] 87/287: Remove "Z" in theme component, Matthew Fidler, 2014/07/02
- [elpa] 144/287: Generate image based on options, Matthew Fidler, 2014/07/02
- [elpa] 86/287: Always suppress shortcuts in read-key-lookup, Matthew Fidler, 2014/07/02
- [elpa] 88/287: Apply defered variables/modes. Fix Issue #216, Matthew Fidler, 2014/07/02
- [elpa] 147/287: Allow emacs23 to fail., Matthew Fidler, 2014/07/02
- [elpa] 78/287: Faster ignore globally defined key, Matthew Fidler, 2014/07/02
- [elpa] 149/287: Backport `make-composed-keymap'.,
Matthew Fidler <=
- [elpa] 148/287: Fix more compiler issues and typos, Matthew Fidler, 2014/07/02
- [elpa] 145/287: pushnew instead of add-to-list, Matthew Fidler, 2014/07/02
- [elpa] 152/287: Remove emacs23 testing, Matthew Fidler, 2014/07/02
- [elpa] 150/287: Note that ergoemacs-mode requires emacs 24.1, Matthew Fidler, 2014/07/02
- [elpa] 153/287: Update expections., Matthew Fidler, 2014/07/02
- [elpa] 154/287: Remove ert dependence. Its in emacs 24, Matthew Fidler, 2014/07/02
- [elpa] 151/287: Try to make this a batch test., Matthew Fidler, 2014/07/02
- [elpa] 156/287: Try to make compatible with 24.4, Matthew Fidler, 2014/07/02
- [elpa] 158/287: Take out `mark-whole-buffer', Matthew Fidler, 2014/07/02
- [elpa] 155/287: Use :initialize #'custom-initialize-default, Matthew Fidler, 2014/07/02