forked from mirrors/org-mode
org-fold-hide-drawer-all: Make interactive
* lisp/org-fold.el (org-fold-hide-drawer-all): Convert into interactive command. Accept two optional arguments - region boundaries. * etc/ORG-NEWS (~org-fold-hide-drawer-all~ is now interactive): Document the change. Link: https://orgmode.org/list/CAFmwT7WEMvGVyQhP8NcZY5vZMzz4NcvBjchd4jBqgHCPwjOgFA@mail.gmail.com
This commit is contained in:
parent
c77e7f9c8a
commit
13353f1fa3
|
@ -626,6 +626,11 @@ Maxima's graphics packages (~draw~ or ~plot~); the default remains
|
|||
of the file-name set in the ~:file~ header argument.
|
||||
|
||||
** New functions and changes in function arguments
|
||||
*** ~org-fold-hide-drawer-all~ is now interactive
|
||||
|
||||
~org-fold-hide-drawer-all~ is now a command, accepting two optional
|
||||
arguments - region to act on.
|
||||
|
||||
*** =TYPES= argument in ~org-element-lineage~ can now be a symbol
|
||||
|
||||
When =TYPES= is symbol, only check syntax nodes of that type.
|
||||
|
|
|
@ -593,10 +593,11 @@ Return a non-nil value when toggling is successful."
|
|||
(interactive)
|
||||
(org-block-map (apply-partially #'org-fold-hide-block-toggle 'hide)))
|
||||
|
||||
(defun org-fold-hide-drawer-all ()
|
||||
"Fold all drawers in the current buffer."
|
||||
(let ((begin (point-min))
|
||||
(end (point-max)))
|
||||
(defun org-fold-hide-drawer-all (&optional begin end)
|
||||
"Fold all drawers in the current buffer or active region BEGIN..END."
|
||||
(interactive "r")
|
||||
(let ((begin (or begin (point-min)))
|
||||
(end (or end (point-max))))
|
||||
(org-fold--hide-drawers begin end)))
|
||||
|
||||
(defun org-fold--hide-drawers (begin end)
|
||||
|
|
Loading…
Reference in New Issue