[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] externals/ergoemacs-mode 37fc1c8 233/325: Remove ergoemacs-theme-
From: |
Stefan Monnier |
Subject: |
[elpa] externals/ergoemacs-mode 37fc1c8 233/325: Remove ergoemacs-theme-component--parse |
Date: |
Sat, 23 Oct 2021 18:49:00 -0400 (EDT) |
branch: externals/ergoemacs-mode
commit 37fc1c84a066b526b0a76e7d06d9db0548fa9085
Author: Walter Landry <wlandry@caltech.edu>
Commit: Walter Landry <wlandry@caltech.edu>
Remove ergoemacs-theme-component--parse
---
ergoemacs-macros.el | 133 ----------------------------------------------------
ergoemacs-themes.el | 4 +-
2 files changed, 2 insertions(+), 135 deletions(-)
diff --git a/ergoemacs-macros.el b/ergoemacs-macros.el
index c5a1996..79ed47b 100644
--- a/ergoemacs-macros.el
+++ b/ergoemacs-macros.el
@@ -52,17 +52,6 @@ If SYMBOL is void, return nil"
(ignore-errors (symbol-value ,symbol))))
;; This shouldn't be called at run-time; This fixes the byte-compile warning.
-(fset 'ergoemacs-theme-component--parse
- #'(lambda(keys-and-body &optional skip-first)
- "Parse KEYS-AND-BODY, optionally skipping the name and
-documentation with SKIP-FIRST.
-
-Uses `ergoemacs-theme-component--parse-keys-and-body' and
- `ergoemacs-theme-component--parse-remaining'."
- (ergoemacs-theme-component--parse-keys-and-body
- keys-and-body
- 'ergoemacs-theme-component--parse-remaining
- skip-first)))
(fset 'ergoemacs-theme-component--parse-key-str
#'(lambda (str)
@@ -113,128 +102,6 @@ Uses `ergoemacs-theme-component--parse-keys-and-body' and
`(quote ,fun)))
fun))))
-;;;###autoload
-(defun ergoemacs-theme-component--parse-remaining (remaining)
- "Parse the REMAINING list, and convert:
-
-- `define-key' is converted to
- `ergoemacs-component-struct--define-key' and keymaps are quoted.
-
-- `global-set-key' is converted to
- `ergoemacs-component-struct--define-key' with keymap equal to
- `global-map'.
-
-- `bind-key' is converted to
- `ergoemacs-component-struct--define-key'.
-
-- `global-unset-key' is converted to
- `ergoemacs-component-struct--define-key' with keymap equal to
- `global-map' and function definition is nil.
-
-- `global-reset-key' is converted
- `ergoemacs-component-struct--define-key'
-
-- `setq' and `set' is converted to
- `ergoemacs-component-struct--set'
-
-- `add-hook' and `remove-hook' is converted to
- `ergoemacs-component-struct--set'
-
-- Mode initialization like (delete-selection-mode 1)
- or (delete-selection) is converted to
- `ergoemacs-component-struct--set'
-
-- Allows :version statement expansion to
- `ergoemacs-component-struct--new-version'
-
-- Adds with-hook syntax or (when -hook) or (when -mode) using
- `ergoemacs-component-struct--with-hook'
-
-Since `ergoemacs-mode' tries to distinguish return, escape, and
-tab from their ASCII equivalents In the GUI, the following Emacs
-keyboard codes are converted to keys that `ergoemacs-mode' can
-distinguish from the ASCII equivalents:
-
-- C-i (TAB) is changed to <C-i>
-
-- C-m (RET) is changed to <C-m>
-
-- C-[ (ESC) is changed to <C-]>"
- (let* ((last-was-version nil)
- (remaining
- (mapcar
- (lambda(elt)
- (cond
- (last-was-version
- (setq last-was-version nil)
- (if (stringp elt)
- `(ergoemacs-component-struct--new-version ,elt)
- `(ergoemacs-component-struct--new-version ,(symbol-name
elt))))
- ((ignore-errors (eq elt ':version))
- (setq last-was-version t)
- nil)
- ((ignore-errors (eq (nth 0 elt) 'global-reset-key))
- `(ergoemacs-component-struct--define-key 'global-map
,(ergoemacs-theme-component--parse-key (nth 1 elt)) nil))
- ((ignore-errors (eq (nth 0 elt) 'global-unset-key))
- `(ergoemacs-component-struct--define-key 'global-map
,(ergoemacs-theme-component--parse-key (nth 1 elt)) nil))
- ((ignore-errors (eq (nth 0 elt) 'set))
- ;; Currently doesn't support (setq a b c d ), but it should.
- `(ergoemacs-component-struct--set ,(nth 1 elt) '(lambda() ,(nth
2 elt))))
- ((ignore-errors (eq (nth 0 elt) 'add-hook))
- `(ergoemacs-component-struct--set ,(nth 1 elt) ,(nth 2 elt)
- (list t ,(nth 3 elt) ,(nth 4
elt))))
- ((ignore-errors (eq (nth 0 elt) 'remove-hook))
- `(ergoemacs-component-struct--set ,(nth 1 elt) ,(nth 2 elt)
- (list nil nil ,(nth 3 elt))))
- ((ignore-errors (memq (nth 0 elt) '(setq setq-default)))
- ;; in the theme component `setq' is equivalent to
- ;; `seq-default' since the component uses `set' and
`set-default'
- (let ((tmp-elt elt)
- (ret '()))
- (pop tmp-elt)
- (while (and (= 0 (mod (length tmp-elt) 2)) (< 0 (length
tmp-elt)))
- (push `(ergoemacs-component-struct--set (quote ,(pop
tmp-elt)) '(lambda() ,(pop tmp-elt))) ret))
- (push 'progn ret)
- ret))
- ((ignore-errors (string-match "-mode$" (symbol-name (nth 0
elt))))
- `(ergoemacs-component-struct--set (quote ,(nth 0 elt))
'(lambda() ,(nth 1 elt))))
- ((ignore-errors (eq (nth 0 elt) 'global-set-key))
- `(ergoemacs-component-struct--define-key 'global-map
,(ergoemacs-theme-component--parse-key (nth 1 elt))
-
,(ergoemacs-theme-component--parse-fun (nth 2 elt))))
-
- ;; (bind-key "C-c x" 'my-ctrl-c-x-command)
- ((ignore-errors (and (eq (nth 0 elt) 'bind-key)
- (= (length elt) 3)))
- `(ergoemacs-component-struct--define-key 'global-map (kbd
,(ergoemacs-theme-component--parse-key-str (nth 1 elt)))
-
,(ergoemacs-theme-component--parse-fun (nth 2 elt))))
-
- ;; (bind-key "C-c x" 'my-ctrl-c-x-command some-other-map)
- ((ignore-errors (and (eq (nth 0 elt) 'bind-key)
- (= (length elt) 4)))
- `(ergoemacs-component-struct--define-key (quote ,(nth 3 elt))
(kbd ,(ergoemacs-theme-component--parse-key-str (nth 1 elt)))
-
,(ergoemacs-theme-component--parse-fun (nth 2 elt))))
-
- ((ignore-errors (eq (nth 0 elt) 'define-key))
- (if (equal (nth 1 elt) '(current-global-map))
- `(ergoemacs-component-struct--define-key 'global-map
,(ergoemacs-theme-component--parse-key (nth 2 elt))
-
,(ergoemacs-theme-component--parse-fun (nth 3 elt)))
- `(ergoemacs-component-struct--define-key (quote ,(nth 1 elt))
,(ergoemacs-theme-component--parse-key (nth 2 elt))
-
,(ergoemacs-theme-component--parse-fun (nth 3 elt)))))
- ((or (ignore-errors (eq (nth 0 elt) 'with-hook))
- (and (ignore-errors (eq (nth 0 elt) 'when))
- (ignore-errors (string-match
"\\(-hook\\|-mode\\|^mark-active\\)$" (symbol-name (nth 1 elt))))))
- (let ((tmp (ergoemacs-theme-component--parse (cdr (cdr elt))
t)))
- `(ergoemacs-component-struct--with-hook
- ',(nth 1 elt) ',(nth 0 tmp)
- '(lambda () ,@(nth 1 tmp)))))
- ((ignore-errors (memq (nth 0 elt) '(dolist when unless if)))
- `(,(car elt) ,(car (cdr elt)) ,@(macroexpand-all
(ergoemacs-theme-component--parse-remaining (cdr (cdr elt))))))
- ((ignore-errors (memq (nth 0 elt) '(ergoemacs-advice defadvice)))
- (macroexpand-all elt))
- (t `(ergoemacs-component-struct--deferred ',elt))))
- remaining)))
- remaining))
-
(defvar ergoemacs-theme-component-properties
'(:bind
:bind-keymap
diff --git a/ergoemacs-themes.el b/ergoemacs-themes.el
index 7c5e85e..38af446 100644
--- a/ergoemacs-themes.el
+++ b/ergoemacs-themes.el
@@ -424,8 +424,8 @@ calling any other ergoemacs-set-* function"
)
(defun ergoemacs-set-move-buffer (keymap)
- (ergoemacs-define-key keymap (kbd "M-n")
'ergoemacs-beginning-or-end-of-buffer)
- (ergoemacs-define-key keymap (kbd "M-N")
'ergoemacs-end-or-beginning-of-buffer)
+ (ergoemacs-define-key keymap (kbd "M-n") 'beginning-of-buffer)
+ (ergoemacs-define-key keymap (kbd "M-N") 'end-of-buffer)
(ergoemacs-define-key isearch-mode-map (kbd "M-n")
'isearch-beginning-of-buffer)
(ergoemacs-define-key isearch-mode-map (kbd "M-N") 'isearch-end-of-buffer)
- [elpa] externals/ergoemacs-mode efc8751 249/325: Some fixes based on emacs elpa requirements, (continued)
- [elpa] externals/ergoemacs-mode efc8751 249/325: Some fixes based on emacs elpa requirements, Stefan Monnier, 2021/10/23
- [elpa] externals/ergoemacs-mode 69abf8d 250/325: Fix ergoemacs-calculate-bindings, Stefan Monnier, 2021/10/23
- [elpa] externals/ergoemacs-mode bed9aa1 253/325: Fix ergoemacs-mode and ergoemacs-themes; turn on cua mode, Stefan Monnier, 2021/10/23
- [elpa] externals/ergoemacs-mode 57e8e17 257/325: remove undo-tree and mark-active, Stefan Monnier, 2021/10/23
- [elpa] externals/ergoemacs-mode edc154f 272/325: Add theme for the ergoemacs keys hash. Also reduce tests, Stefan Monnier, 2021/10/23
- [elpa] externals/ergoemacs-mode 09bc371 278/325: Restore menu items after turning off ergoemacs, Stefan Monnier, 2021/10/23
- [elpa] externals/ergoemacs-mode f14b71e 281/325: Remove ergoemacs-mode support for term-mode, Stefan Monnier, 2021/10/23
- [elpa] externals/ergoemacs-mode f3ebfc1 298/325: Add input-pending-p to echoing of commands, Stefan Monnier, 2021/10/23
- [elpa] externals/ergoemacs-mode 349d05a 300/325: Remove describe theme, Stefan Monnier, 2021/10/23
- [elpa] externals/ergoemacs-mode 00e00a6 230/325: Remove ergoemacs-component-struct, Stefan Monnier, 2021/10/23
- [elpa] externals/ergoemacs-mode 37fc1c8 233/325: Remove ergoemacs-theme-component--parse,
Stefan Monnier <=
- [elpa] externals/ergoemacs-mode 6f703fe 235/325: Remove ergoemacs-advice, Stefan Monnier, 2021/10/23
- [elpa] externals/ergoemacs-mode d0004ec 241/325: Remove more -map functions, Stefan Monnier, 2021/10/23
- [elpa] externals/ergoemacs-mode ea88aad 247/325: Add back the command loop, Stefan Monnier, 2021/10/23
- [elpa] externals/ergoemacs-mode d43bb0a 248/325: Fix command loop, Stefan Monnier, 2021/10/23
- [elpa] externals/ergoemacs-mode 87b722e 251/325: Make calculate ergoemacs bindings an interactive function, Stefan Monnier, 2021/10/23
- [elpa] externals/ergoemacs-mode 4c1fe49 252/325: Fix some issues, Stefan Monnier, 2021/10/23
- [elpa] externals/ergoemacs-mode b7f909a 254/325: Some fixes, Stefan Monnier, 2021/10/23
- [elpa] externals/ergoemacs-mode f28dc66 255/325: Add some active keymaps to ergoemacs-mode (like before), Stefan Monnier, 2021/10/23
- [elpa] externals/ergoemacs-mode ecb9ac7 256/325: Align some more of the keys with what was there before. Add redo, Stefan Monnier, 2021/10/23
- [elpa] externals/ergoemacs-mode 9e58dd5 261/325: Simplify, Stefan Monnier, 2021/10/23