diff options
| author | Julian Hoch <95583314+julian-hoch@users.noreply.github.com> | 2025-09-27 18:01:28 +0200 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2025-09-28 00:01:28 +0800 |
| commit | f59dacc9fd8501631cbefc09057c91ed95cdf318 (patch) | |
| tree | 689ecbfd4cf7c10f7a685f9054f923887a4ce193 /modes/hideshow | |
| parent | d86fee779cf6ad557eb49f9f68b520e8ab1c32e7 (diff) | |
hideshow: zL for hs-hide-level
Diffstat (limited to 'modes/hideshow')
| -rw-r--r-- | modes/hideshow/evil-collection-hideshow.el | 45 |
1 files changed, 45 insertions, 0 deletions
diff --git a/modes/hideshow/evil-collection-hideshow.el b/modes/hideshow/evil-collection-hideshow.el new file mode 100644 index 0000000..ba27d84 --- /dev/null +++ b/modes/hideshow/evil-collection-hideshow.el @@ -0,0 +1,45 @@ +;;; evil-collection-hideshow --- Bindings for `hideshow' -*- lexical-binding: t; -*- + +;; Copyright (C) 2025 Julian Hoch + +;; Author: Julian Hoch <julianhoch@web.de> +;; Maintainer: Julian Hoch <julianhoch@web.de> +;; Created: 2025-09-27 +;; Keywords: evil, emacs, tools +;; URL: https://github.com/emacs-evil/evil-collection + +;; This file is not part of GNU Emacs. + +;; This program is free software; you can redistribute it and/or modify +;; it under the terms of the GNU General Public License as published by +;; the Free Software Foundation, either version 3 of the License, or +;; (at your option) any later version. + +;; This program is distributed in the hope that it will be useful, +;; but WITHOUT ANY WARRANTY; without even the implied warranty of +;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +;; GNU General Public License for more details. + +;; You should have received a copy of the GNU General Public License +;; along with this program. If not, see <http://www.gnu.org/licenses/>. + +;;; Commentary: +;;; Bindings for `hideshow'. + +;;; Code: +(require 'evil-collection) +(require 'hideshow nil t) + +(declare-function hs-hide-level "hideshow") +(defvar hs-minor-mode-map) +(defconst evil-collection-hideshow-maps '(hs-minor-mode-map)) + +;;;###autoload +(defun evil-collection-hideshow-setup () + "Set up `evil' bindings for `hideshow'." + (evil-set-initial-state 'hs-minor-mode 'normal) + (evil-collection-define-key 'normal 'hs-minor-mode-map + "zL" 'hs-hide-level)) + +(provide 'evil-collection-hideshow) +;;; evil-collection-hideshow.el ends here |
