[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [O] Completely hide the :PROPERTIES: drawer in org-mode.
From: |
Marco Wahl |
Subject: |
Re: [O] Completely hide the :PROPERTIES: drawer in org-mode. |
Date: |
Wed, 13 Feb 2019 19:44:47 +0100 |
User-agent: |
Gnus/5.13 (Gnus v5.13) |
> More generally, I feel uneasy about completely hiding stuff. Org format
> is not meant to be opaque. I think the current situation is fine, as far
> as /core/ Org is concerned. Of course, users are free to extend it to
> their own needs.
Yes, indeed.
Occasionally I use
#v+
#+begin_src elisp
; lexical binding, please!
(let (ols)
(defun mw-org-hide-meta-heading-info ()
"Hide meta data following headings."
(interactive)
(org-show-all) ; expand all props before make invisible to avoid ellipses.
(save-excursion
(goto-char (point-min))
(unless (org-at-heading-p) (outline-next-heading))
(while (not (eobp))
(let ((beg (1+ (progn (end-of-line) (point))))
(end (1- (progn (org-end-of-meta-data t) (point)))))
(when (< beg end)
(push (make-overlay beg end) ols)
(overlay-put (car ols) 'invisible t)))
(when (not (org-at-heading-p))
(outline-next-heading)))))
(defun mw-org-show-meta-info-lines ()
"Show meta info."
(interactive)
(mapc #'delete-overlay ols)
(setq ols nil)))
#+end_src
#v-
to completely get the property meta stuff out of sight.
Ciao,
--
Marco
GPG: http://pgp.mit.edu/pks/lookup?search=0x49010A040A3AE6F2
- [O] Completely hide the :PROPERTIES: drawer in org-mode., Keith David Bershatsky, 2019/02/07
- Re: [O] Completely hide the :PROPERTIES: drawer in org-mode., Nicolas Goaziou, 2019/02/12
- Re: [O] Completely hide the :PROPERTIES: drawer in org-mode., Michaël Cadilhac, 2019/02/12
- Re: [O] Completely hide the :PROPERTIES: drawer in org-mode., Nicolas Goaziou, 2019/02/13
- Re: [O] Completely hide the :PROPERTIES: drawer in org-mode., Michaël Cadilhac, 2019/02/13
- Re: [O] Completely hide the :PROPERTIES: drawer in org-mode., Nicolas Goaziou, 2019/02/13
- Re: [O] Completely hide the :PROPERTIES: drawer in org-mode., Michaël Cadilhac, 2019/02/14
- Re: [O] Completely hide the :PROPERTIES: drawer in org-mode., Nicolas Goaziou, 2019/02/14
- Re: [O] Completely hide the :PROPERTIES: drawer in org-mode., Michaël Cadilhac, 2019/02/14
- Re: [O] Completely hide the :PROPERTIES: drawer in org-mode., Nicolas Goaziou, 2019/02/14
- Re: [O] Completely hide the :PROPERTIES: drawer in org-mode.,
Marco Wahl <=