Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/karimaziev/hideshow-extra
Additional hideshow commands.
https://github.com/karimaziev/hideshow-extra
Last synced: 4 days ago
JSON representation
Additional hideshow commands.
- Host: GitHub
- URL: https://github.com/karimaziev/hideshow-extra
- Owner: KarimAziev
- License: gpl-3.0
- Created: 2023-01-24T10:27:59.000Z (almost 2 years ago)
- Default Branch: main
- Last Pushed: 2024-11-09T12:22:04.000Z (5 days ago)
- Last Synced: 2024-11-09T13:24:17.860Z (5 days ago)
- Language: Emacs Lisp
- Size: 713 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.org
- License: LICENSE
Awesome Lists containing this project
README
* hideshow-extra
Additional =hideshow= commands.
[[./hideshow-extra.gif][./hideshow-extra.gif]]
** Installation
Emacs >= 25.1 is required.
*** Manual
1. Download the source code and put it wherever you like, e.g. into =~/.emacs.d/hideshow-extra/=
#+begin_src shell :eval no
git clone https://github.com/KarimAziev/hideshow-extra.git ~/.emacs.d/hideshow-extra/
#+end_src2. Add the downloaded directory to the load path:
#+begin_src elisp :eval no
(add-to-list 'load-path "~/.emacs.d/hideshow-extra/")
(require 'hideshow-extra)
#+end_src#+begin_src elisp :eval no
(use-package hideshow-extra
:straight (hideshow-extra
:repo "KarimAziev/hideshow-extra"
:type git
:host github)
:bind ((:map hideshow-extra-mode-map
("TAB" . hideshow-extra-toggle-or-indent)
("S-" . hideshow-extra-cycle)))
:hook ((emacs-lisp-mode . hideshow-extra-mode)
(hideshow-extra-mode . hideshow-extra-hide-initial-comment-block)))
#+end_src** Commands and modes
*** ~hideshow-extra-mode~Minor mode that will activate keymap =hideshow-extra-mode-map= with such commands:
| Key | Command |
|-----------+-----------------------------------|
| =TAB= | =hideshow-extra-toggle-or-indent= |
| =S-= | =hideshow-extra-cycle= |*** ~hideshow-extra-cycle~
Cycle commands defined in the custom variable =hideshow-extra-toggle-all-modes=.
*** ~hideshow-extra-toggle-or-indent~
Toggle hiding/showing a of block or invoke =indent-for-tab-command=. Inside string or comments call =indent-for-tab-command=. otherwise activate =hs-minor-mode= and toggle hiding.*** ~hideshow-extra-narrow-to-docs~
Hide all blocks except documentation strings.*** ~hideshow-extra-toggle-all-down~
Toggle folding for nodes after point.
*** ~hideshow-extra-toggle-all-up~
Toggle folding for nodes before point.
*** ~hideshow-extra-toggle-all-keep-current~
Toggle folding for all nodes except current.
*** ~hideshow-extra-toggle-all~
Toggle folding for all nodes.** Customization
*** ~hideshow-extra-recenter-after-toggle~
Whether to recenter window after toggling.
*** ~hideshow-extra-cycle-commands~
List of functions to cycle with command =hideshow-extra-cycle=.
*** ~hideshow-extra-hide-initial-comment-block-condition~
Function to enable or disable =hs-hide-initial-comment-block=. It is called without arguments. If returned value is non-nil, hide initial block silently, otherwise - do nothing.