* 9.6 - hide-drawer-startup option(s?) [9.5.5 (release_9.5.5 @ /usr/local/share/emacs/29.0.50/lisp/org/)]
@ 2022-12-13 7:37 Kévin Le Gouguec
2022-12-13 11:16 ` Ihor Radchenko
0 siblings, 1 reply; 5+ messages in thread
From: Kévin Le Gouguec @ 2022-12-13 7:37 UTC (permalink / raw)
To: emacs-orgmode
Hey Org,
Trying out Emacs 29 and going over ORG-NEWS, this item stands out to me:
> *** A new custom setting =org-hide-drawer-startup= to control initial folding state of drawers
A quick grep for org(-cycle)?-hide-drawer-startup turns this up:
File: etc/ORG-NEWS
459 27 *** A new custom setting =org-hide-drawer-startup= to control initial folding state of drawers
File: lisp/org-cycle.el
128 12 (defcustom org-cycle-hide-drawer-startup t
630 11 (when org-cycle-hide-drawer-startup (org-cycle-hide-drawers 'all))
File: lisp/org.el
4074 20 ("hidedrawers" org-hide-drawer-startup t)
4075 22 ("nohidedrawers" org-hide-drawer-startup nil)
AFAICT those were all introduced in 2022-06-25 "org-cycle.el: New custom
setting `org-cycle-hide-drawer-startup'" (bcfed0f34). Is the patch
below in order, or have I missed something that makes this all work?
(Haven't actually tried the feature and won't be able to before this
evening; sending this speculatively in case things are as simple as they
look. Apologies for the noise if not)
diff --git a/etc/ORG-NEWS b/etc/ORG-NEWS
index 67889c0b1..e3b3f802d 100644
--- a/etc/ORG-NEWS
+++ b/etc/ORG-NEWS
@@ -456,7 +456,7 @@ options:
=:icalendar-scheduled-summary-prefix=,
=:icalendar-deadline-summary-prefix=
-*** A new custom setting =org-hide-drawer-startup= to control initial folding state of drawers
+*** A new custom setting =org-cycle-hide-drawer-startup= to control initial folding state of drawers
Previously, all the drawers were always folded when opening an Org
file. This only had an effect on the drawers outside folded
diff --git a/lisp/org.el b/lisp/org.el
index 3018e4d6f..80e44d85a 100644
--- a/lisp/org.el
+++ b/lisp/org.el
@@ -4071,8 +4071,8 @@ After a match, the following groups carry important information:
("noptag" org-tag-persistent-alist nil)
("hideblocks" org-hide-block-startup t)
("nohideblocks" org-hide-block-startup nil)
- ("hidedrawers" org-hide-drawer-startup t)
- ("nohidedrawers" org-hide-drawer-startup nil)
+ ("hidedrawers" org-cycle-hide-drawer-startup t)
+ ("nohidedrawers" org-cycle-hide-drawer-startup nil)
("beamer" org-startup-with-beamer-mode t)
("entitiespretty" org-pretty-entities t)
("entitiesplain" org-pretty-entities nil))
^ permalink raw reply related [flat|nested] 5+ messages in thread
* Re: 9.6 - hide-drawer-startup option(s?) [9.5.5 (release_9.5.5 @ /usr/local/share/emacs/29.0.50/lisp/org/)]
2022-12-13 7:37 9.6 - hide-drawer-startup option(s?) [9.5.5 (release_9.5.5 @ /usr/local/share/emacs/29.0.50/lisp/org/)] Kévin Le Gouguec
@ 2022-12-13 11:16 ` Ihor Radchenko
2022-12-13 18:34 ` Kévin Le Gouguec
0 siblings, 1 reply; 5+ messages in thread
From: Ihor Radchenko @ 2022-12-13 11:16 UTC (permalink / raw)
To: Kévin Le Gouguec; +Cc: emacs-orgmode
Kévin Le Gouguec <kevin.legouguec@gmail.com> writes:
> Trying out Emacs 29 and going over ORG-NEWS, this item stands out to me:
>
>> *** A new custom setting =org-hide-drawer-startup= to control initial folding state of drawers
>
> A quick grep for org(-cycle)?-hide-drawer-startup turns this up:
>
> File: etc/ORG-NEWS
> 459 27 *** A new custom setting =org-hide-drawer-startup= to control initial folding state of drawers
>
> File: lisp/org-cycle.el
> 128 12 (defcustom org-cycle-hide-drawer-startup t
> 630 11 (when org-cycle-hide-drawer-startup (org-cycle-hide-drawers 'all))
>
> File: lisp/org.el
> 4074 20 ("hidedrawers" org-hide-drawer-startup t)
> 4075 22 ("nohidedrawers" org-hide-drawer-startup nil)
Thanks for the heads-up!
Fixed on bugfix.
https://git.savannah.gnu.org/cgit/emacs/org-mode.git/commit/?id=4323a19b1
https://git.savannah.gnu.org/cgit/emacs/org-mode.git/commit/?id=47bcdce19
--
Ihor Radchenko // yantar92,
Org mode contributor,
Learn more about Org mode at <https://orgmode.org/>.
Support Org development at <https://liberapay.com/org-mode>,
or support my work at <https://liberapay.com/yantar92>
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: 9.6 - hide-drawer-startup option(s?) [9.5.5 (release_9.5.5 @ /usr/local/share/emacs/29.0.50/lisp/org/)]
2022-12-13 11:16 ` Ihor Radchenko
@ 2022-12-13 18:34 ` Kévin Le Gouguec
2022-12-13 18:42 ` Ihor Radchenko
0 siblings, 1 reply; 5+ messages in thread
From: Kévin Le Gouguec @ 2022-12-13 18:34 UTC (permalink / raw)
To: Ihor Radchenko; +Cc: emacs-orgmode
Ihor Radchenko <yantar92@posteo.net> writes:
> Thanks for the heads-up!
> Fixed on bugfix.
> https://git.savannah.gnu.org/cgit/emacs/org-mode.git/commit/?id=4323a19b1
> https://git.savannah.gnu.org/cgit/emacs/org-mode.git/commit/?id=47bcdce19
Fixes duly noted, thanks 🙏
Just to make sure I understand this new setting correctly: by default,
despite org-cycle-hide-drawer-startup being t, it's ineffectual, because
org-startup-folded defaults to 'showeverything, right?
(Asking because when reading the ORG-NEWS entry for the new option in
isolation…
> The new custom setting gives more control over initial folding state
> of the drawers. When set to =nil= (default is =t=), the drawers are
> not folded on startup.
… my initial reaction was "oh neat so LOGBOOKs will be folded on startup
by default", until I tried, got surprised they remained open, frowned
for a moment, then remembered this other bit…
> **** Folding state of the drawers is now preserved when cycling headline visibility
>
> In the past drawers were folded every time a headline is unfolded.
>
> Now, it is not the case anymore. The drawer folding state is
> preserved. The initial folding state of all the drawers in buffer is
> set according to the startup visibility settings.
… then it clicked)
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: 9.6 - hide-drawer-startup option(s?) [9.5.5 (release_9.5.5 @ /usr/local/share/emacs/29.0.50/lisp/org/)]
2022-12-13 18:34 ` Kévin Le Gouguec
@ 2022-12-13 18:42 ` Ihor Radchenko
2022-12-14 6:18 ` Kévin Le Gouguec
0 siblings, 1 reply; 5+ messages in thread
From: Ihor Radchenko @ 2022-12-13 18:42 UTC (permalink / raw)
To: Kévin Le Gouguec; +Cc: emacs-orgmode
Kévin Le Gouguec <kevin.legouguec@gmail.com> writes:
> Just to make sure I understand this new setting correctly: by default,
> despite org-cycle-hide-drawer-startup being t, it's ineffectual, because
> org-startup-folded defaults to 'showeverything, right?
Yes
> (Asking because when reading the ORG-NEWS entry for the new option in
> isolation…
You can try to play around with
#+startup: nofold hidedrawers hideblocks
:drawer:
asd
:end:
#+begin_src emacs-lisp
(message "heelo")
#+end_src
* This is test
--
Ihor Radchenko // yantar92,
Org mode contributor,
Learn more about Org mode at <https://orgmode.org/>.
Support Org development at <https://liberapay.com/org-mode>,
or support my work at <https://liberapay.com/yantar92>
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: 9.6 - hide-drawer-startup option(s?) [9.5.5 (release_9.5.5 @ /usr/local/share/emacs/29.0.50/lisp/org/)]
2022-12-13 18:42 ` Ihor Radchenko
@ 2022-12-14 6:18 ` Kévin Le Gouguec
0 siblings, 0 replies; 5+ messages in thread
From: Kévin Le Gouguec @ 2022-12-14 6:18 UTC (permalink / raw)
To: Ihor Radchenko; +Cc: emacs-orgmode
Ihor Radchenko <yantar92@posteo.net> writes:
> Kévin Le Gouguec <kevin.legouguec@gmail.com> writes:
>
>> Just to make sure I understand this new setting correctly: by default,
>> despite org-cycle-hide-drawer-startup being t, it's ineffectual, because
>> org-startup-folded defaults to 'showeverything, right?
>
> Yes
Gotcha 👌
>> (Asking because when reading the ORG-NEWS entry for the new option in
>> isolation…
>
> You can try to play around with
>
> #+startup: nofold hidedrawers hideblocks
Yup, all makes sense now. I think customizing org-startup-folded to
'nofold ≡ 'showall is the way to go for me; that will take care of
automatically hiding humongous LOGBOOKs.
Thanks again for the help!
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2022-12-14 6:20 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2022-12-13 7:37 9.6 - hide-drawer-startup option(s?) [9.5.5 (release_9.5.5 @ /usr/local/share/emacs/29.0.50/lisp/org/)] Kévin Le Gouguec
2022-12-13 11:16 ` Ihor Radchenko
2022-12-13 18:34 ` Kévin Le Gouguec
2022-12-13 18:42 ` Ihor Radchenko
2022-12-14 6:18 ` Kévin Le Gouguec
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).