From d1a622cf8e03e829ac30086178cab61b64282521 Mon Sep 17 00:00:00 2001 From: Kévin Le Gouguec Date: Wed, 14 Apr 2021 22:59:28 +0200 Subject: Enable repeat-mode for Emacs≥28 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .emacs | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) (limited to '.emacs') diff --git a/.emacs b/.emacs index 8290a1d..fb30d26 100644 --- a/.emacs +++ b/.emacs @@ -36,14 +36,14 @@ (global-set-key (kbd "C-x C-b") 'ibuffer) -(defun my/other-window (count &optional all-frames) - (interactive "p") - (let ((repeat-map (make-sparse-keymap))) - (define-key repeat-map [?o] #'other-window) - (set-transient-map repeat-map t) - (other-window count all-frames))) - -(global-set-key (kbd "C-x o") #'my/other-window) +(when (< emacs-major-version 28) + (defun my/other-window (count &optional all-frames) + (interactive "p") + (let ((repeat-map (make-sparse-keymap))) + (define-key repeat-map [?o] #'other-window) + (set-transient-map repeat-map t) + (other-window count all-frames))) + (global-set-key (kbd "C-x o") #'my/other-window)) ;; Hopefully these will be easier to remember than TeX commands: -- cgit v1.2.3